Using the Value of a variable in an expression

  • Thread starter Thread starter Bob W
  • Start date Start date
B

Bob W

I have done this before but forgot how.
I want to assign "Smith" to a report textbox with a programed defined
name- FAMA.
Dim strSuffix As String, strVariable As String
strSuffix = "A"
strVariable = "FAM" & strSuffix
?strVariable? = "Smith"
where ? ? is desired punctuation to indicate to use the value of this
variable, not the name.
 
I have done this before but forgot how.
I want to assign "Smith" to a report textbox with a programed defined
name- FAMA.
Dim strSuffix As String, strVariable As String
strSuffix = "A"
strVariable = "FAM" & strSuffix
?strVariable? = "Smith"
where ? ? is desired punctuation to indicate to use the value of this
variable, not the name.

Try Me.Controls(strVariable) = "Smith"


John W. Vinson[MVP]
 
Back
Top