As you can guess, I'm kind of new to .NET and just want to reference a control on one form from another.
Usually I would just do Form.Control.Property but that doesn't work and every example I've found through Google doesn't work for me.
It just seems overly complicated with public classes, etc.
Is there a more simpler way to do this? I'm ready to throw in the towel and just use a global variable at this point.
I have the form containing the control I want to reference, frmGenerate which has a textbox called txtCustomerNo.
From this form through a button's click event I want to show another form, frmCustomers, and have that form reference the value in txtCustomerNo.
frmCustomers.ShowDialog()
It has to be something simple that I'm just not grasping.
See Question&Answers more detail:os