Notes on Arrays
I just checked the referring searches list & found that someone was looking for how to get an array’s length in IAS. Well, here’s my 5 minutes worth of notes on arrays. All IAS arrays are one based (indexes start at one). You can refer to a single index (VariableName[#]) or the entire array (VariableName[]). I’m breaking the rest of the information down into two parts: UDA arrays & local script variable arrays.
UDA Arrays
I’m starting with a simple integer array for these examples (see below). In the script below, I show examples of getting an array’s size, iterating the array, a fast way of clearing out an array, and a way to resize an array on the fly. UDA arrays cannot be extended, but I have seen them take on a bad quality when coping extended values into them. The only way I have found to get them back to a good quality is to use the SetGood(…) function.
Local Variable Arrays
Using local variable arrays is the same as using UDA arrays with a few exceptions. A local variable array cannot be resized by writing to its Length property. The only way I have found of changing its size on the fly is by copying a UDA array to it. This is shown in the picture below.


Nice this is how to redim the array a pain but I uess if I create a UDA as a temp holder – I can then redim it to whatever size I need and then copy local – then I can play array man..
Any ideas on how to use Enumerations with Archestra, for example the radio Control can use Enumerations but for the life of me the Model does not have enumerations for UDA’s
How is an UDA array accessed from InTouch? I have been struggling with this.
Thanks.
I’d like to understand what you are trying to do a little better. Typically you can access object attributes from InTouch via Galaxy:ObjectName.Attribute[ArrayIndex]
If you are doing something different let us know and I’m sure we can help out.
- Andy
I’ve been looking for this info as well. I want to display one element of an ArchestrA array in InTouch and I don’t want to have to set up an IO tag for it. I just want to display it as a value on the HMI. Putting that format into the value display section of a text object errors out telling you that you have invalid characters. It doesn’t like the brackets.
You don’t mess with the format, keep that just like you would display a single number. In the actual value to display you would put something like Me.IntArray[5] to show the 5th element. Hopefully this helps.