bind variable to .net textbox.text property

becak

New Member
im trying to do a simple variable bind to a control text box but i cant for the life of me get this working. Here is the scenario two forms 1 with datagrid and and the other with two textboxes. When i click on the datagrid i would like to pass those variables to the textboxes in FORM1. This is what i have tried with no results.in my form1\[code\]public string myText { get { return tuidInput.Text; } set { tuidInput.Text = value; } } \[/code\]then i my form two when i try to set the value i try this.\[code\]private void selectUser(object sender, DataGridViewCellEventArgs e) { userPicked.tuid = dataGridView1.Rows[dataGridView1.CurrentCell.RowIndex].Cells["spriden_id"].Value.ToString(); userPicked.Name = dataGridView1.Rows[dataGridView1.CurrentCell.RowIndex].Cells["spriden_last_name"].Value.ToString(); Form1 form1 = new Form1(); form1.myText = userPicked.tuid }\[/code\]i got that example from here http://social.msdn.microsoft.com/fo.../thread/7308639f-640b-48bf-8293-abcbfd2292d8/however it does not update the textbox? what should i be doing differentely?what im i doing wrong ? how can i do this correctly i have looked at several article on here but have not been successful at any of them.any help would be great appreciated.
 
Top