hitechboy78737
Programmer
I have an object that has 3 properties: .Q0, .Q1, .Q2
Each property can hold a value between -1 and 3
Each property will set one of 4 checkboxes on a report (not a form) depending on the value.
I want to reference the property in a loop using the property's common name "Q" and an count integer "i"- like .Qi .
This of course won't work.. but how can I make something like this work...
The code:
This loop will save me bucoos of typing if I can make it work.
Thanks for your help!
Kevin Howell
Each property can hold a value between -1 and 3
Each property will set one of 4 checkboxes on a report (not a form) depending on the value.
I want to reference the property in a loop using the property's common name "Q" and an count integer "i"- like .Qi .
This of course won't work.. but how can I make something like this work...
The code:
Code:
For i = 0 to 2
if .Qi = 0 then
ckbx_Ai_0.text = "x"
elseif .Qi = 1
ckbx_Ai_1.text = "x"
elseif .Qi = 2
ckbx_Ai_2.text = "x"
elseif .Qi = 3
ckbx_Ai_3.text = "x"
next
This loop will save me bucoos of typing if I can make it work.
Thanks for your help!
Kevin Howell