Hi everyone,
Just wanted to say thank you for all of your suggestions and coding examples. I will be studying your ideas closely to see if I can implement them in our product. I really
do not have the leeway to alter our product's code structure, I have to live with this fact (argh!!).
Our field variables (the ones we do arithematic on) are set up like:
box1_1 = ''
box1_2 = ''
box1_3 = ''
box1_4 = ''
box1_5 = ''
box1_6 = ''
box1_7 = ''
box1_8 = ''
box1_9 = ''
box1_10 = ''
box1_11 = ''
etc.
The actual amount and thus naming of these variables vary from application to application. Some of the summing operations are quite lengthy as in:
box5_189 = $CUR % (box5_5.to_f + box5_10.to_f + box5_15.to_f + box5_20.to_f + box5_25.to_f + box5_30.to_f + box5_35.to_f + box5_40.to_f + box5_45.to_f + box5_50.to_f + box5_55.to_f + box5_60.to_f + box5_65.to_f + box5_70.to_f + box5_75.to_f + box5_80.to_f + box5_85.to_f + box5_90.to_f + box5_95.to_f + box5_100.to_f + box5_105.to_f + box5_110.to_f + box5_115.to_f + box5_120.to_f + box5_125.to_f + box5_130.to_f + box5_135.to_f + box5_140.to_f + box5_145.to_f + box5_150.to_f + box5_155.to_f + box5_160.to_f + box5_165.to_f + box5_170.to_f + box5_175.to_f + box5_180.to_f + box5_185.to_f + box5_187.to_f)
I will try to find a shortcut method to handle this based on your suggestions, but if I have to manually type in each box name in setting up the implementation, I may
as well just type in the lengthy sum operation as shown above.
Thanks again for all of your help,
Harry Truax