Hide Dynamic Properties in 2D

The Hide dynamic is a simple action, but one that is incredibly useful. When an object is hidden it disappears from view. The object is still active and subject to control programmatically. You might use the Hide dynamic for any one of the following purposes:

Click the Hide button  in the Color section  of the 2D Dynamics ribbon, to create a dynamic that conditionally hides and shows an object during runtime. The properties of the 2D Hide dynamic are shown in the table below. (For the 3D version of this dynamic, refer to Hide Dynamic’s Properties in 3D.) Default values for the Hide dynamic are set in the Preferences tab. Refer to New Hide Default Settings for more information.

 

Unique Properties of the Hide Dynamic

Property

Settings

Description

Data

DataSource

An input, value, expression, or OPC data source

Data connections can be typed directly into the DataSource. Click the Ellipsis button and in Data Browser you can select tags in the system. You can also create Expressions in the Data Browser.

DragDropDataSource

True or False

True indicates that the data source can, during runtime, be dragged by a user and dropped into another component so that the hide dynamic affects the component it is dropped into.

LowLimit

Value

Low limit is used as a boundary condition in animation.

HighLimit

Value

High limit is used as a boundary condition in animation.

HideWhen

Range Settings

Sets discrete ranges when animation occurs.

Dynamic Behavior

AnimationMode

Analog or Discrete

Analog – The fading in and out of the object is determined by values coming from the data source.

Discrete – The start and stop of the object's fading in and out (or showing/not showing) is determined by values coming from the data source.

StartPercent

0 to 100

 

EndPercent

0 to 100

 

AbsoluteOpacity

True or False

Analog AnimationMode only

ExplicitHide

True or False

Discrete AnimationMode only

ExplicitShow

True or False

Discrete AnimationMode only

Dynamic Behavior - Discrete (Discrete AnimationMode only)

StartDelay

Number

The number of milliseconds that will pass before animation begins in runtime; you can use a data source for this number.

Duration

Number

The number of milliseconds over which the animation will transpire; you can use a data source for this number.

SkipInitialDuration

True or False

 

AccelerationRatio

0 to 100

 

DecelerationRatio

0 to 100

 

AnimateWhenTrue

True or False

 

ReverseAnimateWhenFalse

True or False

 

AutoReverse

True or False

 

RepeatCount

Number

 

FillBehavior

Holdend or Stop

 

FreezeWhenNotAnimating

True or False

 

Flash (Discrete AnimationMode only)

FlashRate

Number

The number of milliseconds that will pass between flash state changes; you can use a data source for this number.

HideWhenNotFlashing

True or False

 

Dynamic Behavior - Detents (Analog AnimationMode only)

DetentType

None, Number of Detents, Delta Value

Detents are the number of steps of animation of an object can have.

DetentValue

Number

The number of increments/decrements used in the animation. Use a higher number for smoother animation.

DetentOrigin

Value

The starting analog value from which subsequent steps are calculated.

ToolTip

ShowToolTip

True or False

 

ShowDescription

True, False, or Default

 

ShowDataSourceName

True, False, or Default

 

ShowDataSourceValue

True, False, or Default

 

ShowErrorInformation

True, False, or Default

 

 

For more information, refer to Object Properties.

 

To illustrate how hide dynamics work the dynamic will be applied to the traffic light that was created above. When the lights are off the hide dynamic will remove them from view. To apply the hide dynamic to the traffic light:

  1. Select all three circles in the traffic light and click the Hide dynamic to apply that action to all three circles.

  2. Set the DataSource of the Hide dynamic to localsim:ramp:::0:1000, the ActiveWhen property to (data<=low) OR (data>=high), and the AnimationMode to Discrete.

  3. Select the top circle and set the LowLimt and the HighLimit for the Hide dynamic to 0 and 400, respectively.

  4. Select the middle circle and set the LowLimt and the HighLimit for the Hide dynamic to 401 and 599, respectively.

  5. Select the bottom circle and set the LowLimt and the HighLimit for the Hide dynamic to 600 and 1000, respectively.

  6. Go into runtime and observe the traffic light; it should look similar to the one shown below.

The Traffic Light with Inactive Lights Hidden

The red and green lights are inactive and hidden.

 

See also:

Find and Replace Properties in Displays and Symbols

Preferences