ObjectDCL Banner

Month_SetCurSel Method

Description

This method will select a date.

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.
Year
Integer identifying the year.
Month
Integer identifying the month.
Day
Integer identifying the day.

Return Values

Returns the following according to the situation:

  • T when successful.
  • Nil if the control is not found, is not visible or the date is invalid or not within allowable range.

AutoLISP Syntax

The recommended convention is passing the control identifier directly:

CopyCode imageCopy Code
(Odcl_Month_SetCurSel 
		MyControlReference [as Reference]
		(list
			Year [as Integer]
			Month [as Integer]
			Day [as Integer]))

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

CopyCode imageCopy Code
(Odcl_Month_SetCurSel
		ProjectFile [as String]
		DialogName [as String]
		ControlName [as String]
		(list
			Year [as Integer]
			Month [as Integer]
			Day [as Integer]))

Applies For

MonthPicker.

Example

CopyCode imageCopy Code
; Select a date
(Odcl_Month_SetCurSel MyProject_MyForm_MyControl (list 2009 12 31))

See Also

Month_GetCurSel