Hi nervous,
I don't think this is going to compile as it is.
Code: Select all
CONST Command as string [Cmd]="ABCDEFGHI"
The [Cmd] is a variable and will probably not pass the syntax check.
Code: Select all
CONST Command as string [10]="ABCDEFGHI"
Above will create a constant one dimensional array with 9 elements.
Code: Select all
Const cmd as String[9] = "AB" +
"CD" +
"EF" +
"IL"
This will work too, but is in general the same as before, since it becomes a string with 8 elements again.
Code: Select all
' To select the desired Character pair
Dim Command as String
command = cmd(0) + cmd(1)
'command now has "AB" in String
command = cmd(2) + cmd(3)
'command now has "CD" in String
'Don't know if this is what you are looking for
There is ways to define an array as I think you want, however this would have to be done in a Multi dimensional array.