パラメータの値のデータ型(siVariantType)を戻します。たとえば、チェックボックスパラメータは siBool を戻し、テキストベースのパラメータは siString を戻します(パラメータで指定可能な値の詳細については、siVariantTypeを参照してください)。
注:このプロパティは、Parameter オブジェクト("パラメータ"を戻す)のタイプを参照する SIObject.Type プロパティとは異なります。
// get accessor siVariantType rtn = Parameter.ValueType; |
' ' This example demonstrates the different between Type, ValueType and TypeName(). ' Both a custom parameter and the position of an object are parameter objects ' so they have the same Type. However because one is an integer value and the ' other a double, they have different ValueTypes ' NewScene , false set oRoot = Application.ActiveProject.ActiveScene.Root set oPropSet = oRoot.AddProperty( "Custom_parameter_list", , "Test" ) set oProp = oPropSet.AddParameter( "Var1", siInt4, , , , , , 1, 0, 10 ) Application.LogMessage oProp.Type & " " & TypeName( oProp ) & " " _ & oProp.ValueType & " " & TypeName( oProp.Value ) set obj = GetPrim( "Null" ) set oPosX = obj.Kinematics.Global.Parameters("posx") Application.LogMessage oPosX.Type & " " & TypeName( oPosX ) & " " _ & oPosX.ValueType & " " & TypeName( oPosX.Value ) ' Expected results: ' INFO : "Parameter Parameter 3 Long" ' INFO : "Parameter Parameter 5 Double" |