Control: Host Control
|
Description
Places a Host control in a window. Once configured with the appropriate assembly, class and parameters this allows a means of interaction with a specialised external component.
The dll component has to meet specific requirements in order to be able to be used as a host control.
Creation
Open the destination window to add the Control.
From the Toolbox, select the Control icon, move the pointer into the window and drag out the initial position and size for the control.
Access
If the Property Editor is not displayed, click on Ribbon > Home > Property Editor
Click on the Control. The Properties for the control will appear in the Property Editor panel and allow changes to be made.
In the example above, the Sym3.Example.Gauge.dll is a custom written component to provide a slider. Download the dll from below link and copy to the client machine “C:\Program Files\Sym3\Sym3 Operator\Client” folder and linked to it via the Assembly name and Class name. The dll does not need to be registered.
Assembly Full Name = C:\Program Files\Sym3\Sym3 Operator\Client\Sym3.Example.Gauge.dll
Class Name = Sym3.Example.Gauge.GaugeHorizontal
Parameters = tag=Tag1;min=0;max=100
there’s no validation on parameters, make sure your set Parameters as the example above.
For 32-bit version, copy the dll in “C:\Program Files (x86)\Sym3\Sym3 Operator\Client” folder and use the same path in Assembly Full Name property.
For Vertical Gauge, set Class Name Property as “Sym3.Example.Gauge.GaugeVertical”.
In the example it reads the value from the value supplied by the tag Tag1. When an input box is added with a Binding Value of Tag1 and a new Tag added with name=Tag1 and data type=Byte then entering a value from 0 to 100 displays a percentage on the slider
Warning: The component is loaded when the window is opened and remains in use until Sym3 is exited.
Properties
Name | Description |
---|---|
Name | Name of the control |
Alias | Alias of the control |
General | |
Assembly Full Name | Use the Browse button to select the assembly component (dll) to load. |
Class Name | Enter the class name for this control. Depends upon the component used. |
Parameters | Enter any optional parameters (if required). Depends upon the component used. The example component takes the value it uses from a tag. |
Layout | |
X | X location in the window to place the control |
Y | Y location in the window to place the control |
Width | Default = 20 Width of the control. |
Height | Default = 120 Height of the control. |
Anchor | Which edge of the window the control is anchored to when the window is resized |
Visual | |
Visible | Default = Visible Visibility of the control. |
Binding
The following properties may be bound to a tag
- Visible
Example
Example gauge dll can be downloaded from the following location.
- 32-bit(X86) Library: Sym3.Example.Gauge.dll
- 64-bit(X64) Library: Sym3.Example.Gauge.dll