ObjectDCL Banner

AxControl_SetPictureProperty Method

Description

This method sets a property to a control.

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.
PropertyName
String identifying the property by name.
FileName
String identifying the path to the picture.
PictureID
Picture specifying the picture from the project folder.

Return Values

Returns the following according to the situation:

  • T when successful.
  • Nil if the control is not found, the property does not exist or the property is read-only.

AutoLISP Syntax

The recommended convention is passing the control identifier directly:

CopyCode imageCopy Code
(Odcl_AxControl_SetPictureProperty 
		MyControlReference [as Reference]
		PropertyName [as String]
		FileName [as String])

CopyCode imageCopy Code
(Odcl_AxControl_SetPictureProperty 
		MyControlReference [as Reference]
		PropertyName [as String]
		PictureID [as Picture])

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

CopyCode imageCopy Code
(Odcl_AxControl_SetPictureProperty 
		ProjectFile [as String]
		DialogName [as String]
		ControlName [as String]
		PropertyName [as String]
		FileName [as String])

CopyCode imageCopy Code
(Odcl_AxControl_SetPictureProperty 
		ProjectFile [as String]
		DialogName [as String]
		ControlName [as String]
		PropertyName [as String]
		PictureID [as Picture])

Remarks

See the property of interest to know what string to pass.

Not all properties can be set.

Applies For

ActiveX.

Example

CopyCode imageCopy Code
; Change the property
(Odcl_AxControl_SetPictureProperty MyProject_MyForm_MyControl "SomeProperty" "Picture.bmp")

See Also

AxControl_GetProperty