Thanks for the recommended change to the loop Kerry, I'm currently trying to streamline the code in an application and this has helped me out a lot. I just need to go thru my app and replace all my loops :)
Regards, Peter > I'm wondering if the dot syntax is going to cause me a > problem with my idea. I know this code works as is, the > global variable gStandard1DataRef is a list of around 60 > variables and it works it's way thru the list loading the data. > > LoadListData is another handler just for ref. > > on LoadDataSet datadir > Global gStandard1DataRef > x = 1 > repeat while x < gStandard1DataRef.count + 1 > LoadListData (datadir, gStandard1DataRef[x]) > x = x + 1 > end repeat > end The dot-syntax and bracket access both work. It doesn't matter much which you use--they won't conflict with each other, but I like to stick with one style just for code readability and consistency. Your repeat loop will be a bit more efficient if you structure it like this: refCount= gStandard1DataRef.count repeat with x = 1 to refCount LoadListData (datadir, gStandard1DataRef[x]) end repeat Loops are a bottleneck in Lingo--it's not a true compiled language. I think that putting the x = x + 1 adds extra bytecode that has to be interpreted each time through the loop, while the "repeat with" should be done in machine language. Not sure about that, but it can't hurt. At any rate, saving the count speeds it up, rather than having to access the count property each time through the loop. Cordially, Kerry Thompson [To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]