T
Travis
I have a question about how to get this to work:
I have the following:
Const A As Integer = 0
Const B As Integer = 1
Const C As Integer = 2
etc...
I have a textbox (txtInput) that people can type in. Say they type in "AB"
and hit the button to calculate. I want it to be able to take the string
(strText) (which contains the letters AB) and convert that text into a form
where it recognizes the letters as constants and not a string. AB = 0 (0*1),
but I can't get there because it only sees the text "AB." Its like writing
"class" and class. The first is a string, the other is a keyword. How do I
take the string and get it to see that it's a bunch of constants, not a
string?
Do you get what I'm trying to ask? If they enter in ABC it to do the math of
0*1*2 and output that, not output the text ABC again.
There must be a simple way of doing this that I'm not thinking of?
Thanks!
I have the following:
Const A As Integer = 0
Const B As Integer = 1
Const C As Integer = 2
etc...
I have a textbox (txtInput) that people can type in. Say they type in "AB"
and hit the button to calculate. I want it to be able to take the string
(strText) (which contains the letters AB) and convert that text into a form
where it recognizes the letters as constants and not a string. AB = 0 (0*1),
but I can't get there because it only sees the text "AB." Its like writing
"class" and class. The first is a string, the other is a keyword. How do I
take the string and get it to see that it's a bunch of constants, not a
string?
Do you get what I'm trying to ask? If they enter in ABC it to do the math of
0*1*2 and output that, not output the text ABC again.
There must be a simple way of doing this that I'm not thinking of?
Thanks!