このメソッドは、フィールドの値から整数を取り出します。要求されたデータ型がフィールドのデータ型と異なる場合は、自動的に変換を実行します。変換を実行できない場合は、LCFAIL_INVALID_CONVERT エラーが発生します。
LCField
newInt = thisField.GetInt (index)
パラメータ |
説明 |
---|---|
index |
Long、>= 1。取り出すフィールドのデータ値のインデックス。 |
値 |
説明 |
---|---|
newInt |
Long。thisField の index 番目の値を整数値に変換したものです。 |
Option Public
Uselsx "*lsxlc"
Sub Initialize
Dim Fld As New LCField (LCTYPE_TEXT)
Fld.Text = "1234.56789"
Dim vInt As Long
vInt = Fld.GetInt (1)
Print "The Int representation of the field is " & vInt
End Sub
The Int representation of the field is 1234