Send Topic Feedback | See Object Hierarchy Chart
PC-DMIS 2022.2 Object Library
GetSize Method
Description
This method queries an array of strings and returns the size of the array (the number of items contained in the array).
Syntax
Visual Basic
Public Function GetSize() As Long
Return Type
Long value of the number of strings contained in the array.
Example
This example defines an array of four items and assigns the size of the array to the size variable. It then gets the value of the second item in the array "MiniRoutine2" and assigns that value to the stringItem2 variable.
var stringArray2 = part.GetStringArray();
stringArray2.SetSize(4);
stringArray.SetValue(1, "OP10");
stringArray.SetValue(2, "MiniRoutine2");
stringArray.SetValue(3, "MiniRoutine3");
stringArray.SetValue(4, "MiniRoutine4");
var size = stringArray2.GetSize();
var stringItem2 = stringArray2.GetValue(2);
See Also