ObjectDCL Banner

DwgList_Dir Method

Description

This method will list all Dwg files in the specified directory.

Parameters

MyControlReference
Reference to the control in the form of MyProject_MyForm_MyControl.
ProjectFile
String identifying the project as it was passed in LoadProject.
DialogName
String identifying the dialog by name.
ControlName
String identifying the control by name.
sDirectory
String identifying the path to the directory to browse.

Return Values

Returns the following according to the situation:

  • T when successful.
  • Nil if the control is not found.

AutoLISP Syntax

The recommended convention is passing the control identifier directly:

CopyCode imageCopy Code
(Odcl_DwgList_Dir 
		MyControlReference [as Reference]
		sDirectory [as String])

An alternative convention is to identify the control by providing the project file, the dialog name and the control name:

CopyCode imageCopy Code
(Odcl_DwgList_Dir
		ProjectFile [as String]
		DialogName [as String]
		ControlName [as String]
		sDirectory [as String])

Applies For

DwgList.

Example

CopyCode imageCopy Code
; Browse the drawing in this folder
(Odcl_DwgList_Dir MyProject_MyForm_MyControl "C:\Documents and Settings\Default User\Desktop")

See Also

DwgList_GetDir