JavaScript

{dialog.object}getStateInfo Method

Syntax

{dialog.object}.getStateInfo();

Returns

stateDatastring

Returns an & delimited list of name-value pairs.

Description

Get all of the state variable information for the UX component.

Discussion

Gets the data from the UX Component's 'state' object in the form of a string of name value pairs, delimited with & characters.

If you want to read a value from the state object, you do NOT need to use this method. The value can be read directly from the state object. See example below.

Example 

Get the state info as a string of name value pairs

var stateData = {dialog.object}.getStateInfo();

Read the 'myvar1' property from the state info object

var x = {dialog.object}.stateInfo['myvar1'];

You can also set a property in the state info object directly using the {dialog.object}.stateInfo object. For example:

{dialog.object}.stateInfo['myvar1'] = 'alpha';

Property names in the state object are case sensitive and must match the case used to define them exactly.

See Also