get_VariableValue Method
The get_VariableValue method gets the
value of an indexed variable from the SetupNode object. You can use
this method to identify objects (for example, pages) that require
special processing when a variable contains a specific value. This
method is useful when a node contains many child objects and variables.
Description
The following example shows three variables that are associated with the page node,Main_Page,
in the Setup DCO file:<P type="Main_Page">
<V n="ID">0</V> 0
<V n="TYPE">Page</V> 1
<V n="STATUS">0</V> 2 0 Variable
0 (name = ID, value = 0)
1 Variable
1 (name = TYPE, value = Page)
2 Variable
2 (name = STATUS, value = 0)
Syntax
- C#
string get_VariableValue(int nIndex)
Arguments
- nIndex
- The index of the variable, where 0 is the first variable defined in the SetupNode object
C# Example
The following example gets the value of the first variable defined with the page node,Main_Page,
in the Setup DCO:TDCOLib.DCOSetupNode m_oDCOSetupNode = m_oDCOSetup.GetNodeByName(2, "Main_Page");
string varValue = m_oDCOSetupNode.get_VariableValue(0);