How to pass textbox data between two forms?

后端 未结 3 714
旧巷少年郎
旧巷少年郎 2021-01-28 14:14

How to send textbox value to textbox between two forms without Show()/ShowDialog() by button? I want to textBox will get value without open form.

3条回答
  •  梦如初夏
    2021-01-28 14:52

    To access the textbox data you need to use: textBox1.Text

    a form is an object so you can define a method that updates the text box value (you can expose the textbox itself with a public accessor)

提交回复
热议问题