| LayoutMessageGetChar Method (String, Int32) |
Returns the first character of the value of the field identified by
name and index.
Namespace:
OBCOM.NetSwitchLib.Layouts
Assembly:
OBCOM.NetSwitchLib (in OBCOM.NetSwitchLib.dll) Version: 1.48.7760.35650 (1.48.7760.35650)
Syntax public Nullable<char> GetChar(
string name,
int index
)
Public Function GetChar (
name As String,
index As Integer
) As Nullable(Of Char)
Parameters
- name
- Type: SystemString
The name of the field.
- index
- Type: SystemInt32
The occurence index of the field.
Return Value
Type:
NullableChar
The first character of the value of the field identified by
name and
index. It returns
null if the string data starts with the special character
NO-DATA (0x1A).
Exceptions Exception | Condition |
---|
InvalidOperationException |
If this LayoutMessage has no Layout, or if the required field
is not defined in the Layout of this LayoutMessage.
|
IndexOutOfRangeException |
If index is less than "0" (zero) or greater-equal
to the number of occurrences of the field, as indicated by the Occurs property.
|
Remarks
If the value of the field is
NULL it returns
null (see
IsNull for more details).
See Also