Hi,
I'm working on making a an EPOS system for a cafe (It wont actually be used in a cafe, that's just the scenario i've given myself) and i have a form pop up for the employee to enter their name, then they click the "Go" button and the next form pops up and the first one closes.
That all works fine, but what i want is at the top of the second form (the one with all the EPOS-ey options on it) is a label displaying the employees name as they entered it on the first form. In my code i don't actually close the first form, just hide it.
Does anyone know how i can get the info entered into the textbox on one form to appear in a label on another form?
This doesn't really sound like the sort of thing you should be using multiple forms for.
It would be better to make a wizard, by having a parent form, and an area for a user control, which is a panel subclass. Have next buttons which transfer which control is present. I would say keep all the data in an object in the parent form, which gets passed into the user control, which changes it - because objects in C# are reference based, all the data will stay updated in the storage object.
[code]
Label1.Text = Form1.TextBox1.Text
[/code]
Not that hard.
[QUOTE=ddrl46;19105290][code]
Label1.Text = Form1.TextBox1.Text
[/code]
Not that hard.[/QUOTE]
Ah, thank you, i didn't know you could just put in the form name in front of it.
Again, thank you.
Sorry, you need to Log In to post a reply to this thread.