GetProperty

The GetProperty component enable you to access single or multiple properties of a given object at a time.

ScreenShot

Ports

The GetProperty component exposes Control In, Control Out, and Data Out ports by default.

Port Description
Control In Must be connected to the Control Out port of one or more components.
Control Out Must be connected to the Control In port of any other component.
Data In Must be connected to the Data Out port of another component from where data is to be collected. The For Loop component exposes the From and To of the Data In ports.
Dynamic Data Out Must be connected to the Data In port of another component where data is to be displayed (Object). This port is displayed when we add items into the component.

Properties

To edit the properties of the GetProperty component, in the Properties window, change the required property. You can edit the following properties:

Property Description
Search Search for the respective property.
Delay After Execution Specifies the wait time (in seconds) after the action is executed.
Delay Before Execution Specifies the wait time (in seconds) before the action is executed.

Example

Let us consider an example of accessing the Height property of a Sample image.

ScreenShot

To use the Get Property component in this scenario:

  1. In the Toolbox, expand Utilities.
  2. Expand Image Utilities
  3. Drag the ReadFromFile component and drop it in the Design surface.
  4. Mention the File path where the sample image is saved.
  5. To add the GetProperty component from the Toolbox, expand Utilities then expand Reflections.

    • Drag the GetProperty component and drop it in the Design surface.
    • Double click on the GetProperty title bar to launch the Getproperty

    • Click on the ScreenShot to add additional parameters.

    ScreenShot

  6. Add a MessageBox component to display output of the Get Property component.

    • In the Toolbox, expand General.
    • Drag the MessageBox component and drop it on the Design surface.
  7. Connect:
    • The control ports of all components.
    • The Control Out ports of the ReadFromFile component to the Control In ports of the GetProperty component.
    • The Data Out ports of the ReadFromFile component to the Data In ports of the GetProperty component.
    • Now lets connect the Control Out ports of the GetProperty component to the Control In ports of the Message Box component.
    • The Data Out ports of the GetProperty component to the Data In ports of the MessageBox component.
  8. In the toolbar, click Run. The output of the MessageBox Component is displayed.

    ScreenShot