>>I have a combo box to choose values ranging from 0 to whatever.
>>
>>Before I write code to always add one to the table value, and then subtract one when writing to the table, anybody got any better ideas?
Ahh, the reverse of those pesky VB problems! (In recent versions of VB (starting with 5.0 or maybe even 6) you can start an array at any element, so it's easier to overcome).
Here's one suggestion -- if the read/write code is tight enough (i.e. all in one method) you might consider defined constants.
#DEFINE d_0 1
#DEFINE d_1 2...
I use the d_ prefix because AFAIK, you cannot, in foxpro, define one number as another outright.
Here's another suggestion -- write a method to more easily wrap the code you are dealing with -- so you could call THIS.WriteElement(1) and the WriteElement method would do the subtracting for ya.
The whole problem with the world is that fools and fanatics are always so certain of themselves, but wiser people so full of doubts. - Bertrand Russell