To insert a line between each element you would modify your loop like this
Code:
for i = 0 to max
EditBox_1.appendText = _GetString(i, strings, indexes) + "\n"
next
This will insert a line after each element in the list.
As far as the 250 element limitation goes, that was a limitation in the communication protocol itself. This can be overcome, albeit with some difficulty by using two virtual variable objects, each bound to a different section of the table and a pair of global string variables. Imagine the following:
Code:
'Global Code here
dim tablePart1 as string
dim tablePart2 as string
Code:
' Event handler in the OptoVirtualVarible object which queries index 0-249
func QueryStringTableSucceeded(queryID as integer, strings as string, indexes[] as integer)
'This approach is the easiest to demonstrate. There are more efficient ways to tackle this
'if performance becomes an issue.
dim i as integer
dim max as integer
max = len(indexes)-1
TablePart1=""
for i = 0 to max
TablePart1 = TablePart1 + _GetString(i, strings, indexes) + "\n"
next
EditBox_1.value = TablePart1 + TablePart2
endfunc
Code:
' Event handler in the OptoVirtualVarible object which queries index 250-499
func QueryStringTableSucceeded(queryID as integer, strings as string, indexes[] as integer)
'This approach is the easiest to demonstrate. There are more efficient ways to tackle this
'if performance becomes an issue.
dim i as integer
dim max as integer
max = len(indexes)-1
TablePart2=""
for i = 0 to max
TablePart2 = TablePart2 + _GetString(i, strings, indexes) + "\n"
next
EditBox_1.value = TablePart1 + TablePart2
endfunc
Now, I will be honest that performance is something I am concerned about when we are dealing with 500 strings that are large enough to wrap lines on a full screen listbox. I hope that this table is not something that gets queried very often. The two performance bottlenecks are: The communication itself and then the repeated string appends may not be the most efficient possible.