I am working on a form where there are 18 combo boxes and labels, numbered 1 through 18.
This is a brief piece of my code:
*************************************
If my1!position = 4 Then
Me.Combo4.Visible = True
Me.Combo4Label.Visible = True
Me.Combo4Label.Caption = my1!custparameter
Me.Combo4.RowSource = "Select [sel_parmv].[vvalue]
End If
****************************************
my1!position comes from a query assigned the my1 identifier.
Rather than have all of this for each of 18 combo boxes, I would like to be able to have a counter that will increase by 1 up to 18 and then when the 'if' statement executes, process the commands for that combo box and label.
I have tried 'me."combo" & counter.visible=true' but as expected it cannot identify the field.
I have also tried 'parm1="me.combo" & counter'. with this then do 'parm1.visible=true'
Is there a way to tell 'me.' a concatenated field name?
Thanks,
Mike
This is a brief piece of my code:
*************************************
If my1!position = 4 Then
Me.Combo4.Visible = True
Me.Combo4Label.Visible = True
Me.Combo4Label.Caption = my1!custparameter
Me.Combo4.RowSource = "Select [sel_parmv].[vvalue]
End If
****************************************
my1!position comes from a query assigned the my1 identifier.
Rather than have all of this for each of 18 combo boxes, I would like to be able to have a counter that will increase by 1 up to 18 and then when the 'if' statement executes, process the commands for that combo box and label.
I have tried 'me."combo" & counter.visible=true' but as expected it cannot identify the field.
I have also tried 'parm1="me.combo" & counter'. with this then do 'parm1.visible=true'
Is there a way to tell 'me.' a concatenated field name?
Thanks,
Mike