messagebox.show(textbox.text) displays null
Hello :)
I have a textbox in a form which is accessed by another form, and i can't understand why the textbox text is null.
adaugaPolitaRca adaugare1 = (adaugaPolitaRca)Application.OpenForms["adaugaPolitaRca"];
TextBox tb = adaugare1.codClientTxt;
MessageBox.Show(tb.Text);//displays nothing even though i write text in the textbox
Does anybody know what's wrong?