A
aft3rgl0w
hey all, i have a subform which has 3 buttons. i'm writing a function whose
sole inpt variable will be the name of the button. part of the function
changes the caption on the selected button, and I want to use this variable
in there
i've tried the following:
(flt is the name of the button)
function changebut(flt as string)
forms!frmmain!subfrm! & flt & .caption = "X"
end function
of course, this doesn't work, i get a "Compile error: Expected: =" and it
highlights the first ampersand
what's the proper syntax for using a variable as a control name?
sole inpt variable will be the name of the button. part of the function
changes the caption on the selected button, and I want to use this variable
in there
i've tried the following:
(flt is the name of the button)
function changebut(flt as string)
forms!frmmain!subfrm! & flt & .caption = "X"
end function
of course, this doesn't work, i get a "Compile error: Expected: =" and it
highlights the first ampersand
what's the proper syntax for using a variable as a control name?