how to declare a public string with a textbox's text
- by Ian Lundberg
i am trying to do
public string str = txtText.Text;
but it wont let me use txtText.txt so how would I declare that so it can be used everywhere?
I can't use it in the button1_click event because if I do it messes it up because I am having a string retrieve from the textbox and set to the textbox so it doesn't work right so I have to have it retrieve the textbox's text somewhere else then set to it.