Native properties and operations

Relevant for: GUI tests and components

If the test object operations and description properties available for a particular test object do not provide the functionality you need, you can access the native operations and properties of any run-time object in your application using the Object property.

After you insert the .Object method, use the statement completion feature with object properties to view a list of the available native operations and properties of an object.

Tip: If the object is a Web object, you can also reference its native properties in programmatic descriptions using the attribute/property notation.

For more details on the Object property, see your object's properties in the UFT Object Model Reference for GUI Testing.

To see a demonstration of this functionality, go to the UFT Apps Marketplace page and select the Dot Object video.

Retrieving native properties

Use the Object property to access the native properties of any run-time object. For example, you can retrieve the current value of the ActiveX calendar's internal Day property as follows:

Dim MyDay
Set MyDay=Browser("index").Page("Untitled").ActiveX("MSCAL.Calendar.7").Object.Day

Back to top

Activating native operations

Use the Object property to activate the internal operations of any run-time object. For example, you can activate the native focus method of the edit box as follows:

Dim MyWebEditSet 
MyWebEdit=Browser("Mercury Tours").Page("Mercury Tours").WebEdit("username").Object
MyWebEdit.focus

Back to top