ObjectDCL Banner

AxObject_SetProperty Method

Description

This method sets a property to a control.

Parameters

MyOleObject
OleObject to the ActiveX object.
PropertyName
String identifying the property by name.
PropertyValue
The value to set, which can be of the type relevant to the property. A best effort is made to convert the argument to the destination type.

Return Values

Returns the following according to the situation:

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

AutoLISP Syntax

CopyCode imageCopy Code
(Odcl_AxObject_SetProperty 
		MyOleObject [as OleObject]
		PropertyName [as String]
		PropertyValue [as Any])

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
; Get the ActiveX object
(Setq rObject (Odcl_AxControl_GetOleObject MyProject_MyForm_MyControl))
		
; Change the property
(Odcl_AxObject_SetProperty rObject "SomeProperty" T)

; Release the handle to the ActiveX
(Odcl_AxObject_Close rObject)

See Also

AxObject_GetProperty