MFGS Variables
MFGSVariables Public interface
Description
Describes methods and properties available on the static instance object MFGS.Variables
Diagram
flowchart LR classDef interfaceStyle stroke-dasharray: 5 5; classDef abstractStyle stroke-width:4px subgraph VGWWCoreIEx VGWWCoreIEx.IExMFGSVariables[[IExMFGSVariables]] class VGWWCoreIEx.IExMFGSVariables interfaceStyle; endMembers
Methods
Public methods
| Returns | Name |
|---|---|
void | Clear()Clears all session variables. |
object | Get(string name, object defaultValue)Gets the value associated with the specified name. |
object | GetIndex(string name, int index, object defaultValue)Gets the value associated with the specified name and index. |
bool | IsInit(string name)Gets a value that indicates if a variable name exists |
void | Set(string name, object value)Sets the value associated with the specified name. |
void | SetIndex(string name, int index, object value)Sets the value associated with the specified name and index. |
Details
Summary
Describes methods and properties available on the static instance object MFGS.Variables
Methods
Clear
public void Clear()Summary
Clears all session variables.
IsInit
public bool IsInit(string name)Arguments
| Type | Name | Description |
|---|---|---|
string | name | The name of the variable. |
Summary
Gets a value that indicates if a variable name exists
Returns
true if the variable name exists; otherwise false.
Get
public object Get(string name, object defaultValue)Arguments
| Type | Name | Description |
|---|---|---|
string | name | The name of the variable. |
object | defaultValue | The value to return if the name cannot be found. |
Summary
Gets the value associated with the specified name.
Remarks
If a name starts with an underscore (_), that variable is treated as global and can be accessed by all sesssion. In WinWrap VBA, if defaultValue is not specified, a empty string will be returned if name cannot be found.
Returns
The value of the variable if found; otherwise the default value.
GetIndex
public object GetIndex(string name, int index, object defaultValue)Arguments
| Type | Name | Description |
|---|---|---|
string | name | The name of the variable. |
int | index | The index of the variable. |
object | defaultValue | The value to return if the name and index cannot be found. |
Summary
Gets the value associated with the specified name and index.
Remarks
If a name starts with an underscore (_), that variable is treated as global and can be accessed by all sesssion. Indexed variables are stored as name[index], meaning GetIndex(“MYVAR”, 1) is the same as Get(“MYVAR[1]”). In WinWrap VBA, if defaultValue is not specified, an empty string will be returned if name cannot be found.
Returns
The value of the variable if found; otherwise the default value.
Set
public void Set(string name, object value)Arguments
| Type | Name | Description |
|---|---|---|
string | name | The name of the variable. |
object | value | The value to set the variable to. |
Summary
Sets the value associated with the specified name.
Remarks
If a name starts with an underscore (_), that variable is treated as global and can be accessed by all sesssion.
SetIndex
public void SetIndex(string name, int index, object value)Arguments
| Type | Name | Description |
|---|---|---|
string | name | The name of the variable. |
int | index | The index of the variable. |
object | value | The value to set the variable to. |
Summary
Sets the value associated with the specified name and index.
Remarks
If a name starts with an underscore (_), that variable is treated as global and can be accessed by all sesssion. Indexed variables are stored as name[index], meaning SetIndex(“MYVAR”, 1, value) is the same as Set(“MYVAR[1]”, value).
Generated with ModularDoc