pass a value from one form to another

后端 未结 7 1199
Happy的楠姐
Happy的楠姐 2020-11-27 21:10

I have two forms, and I need pass a value from form1.textbox1 to form2.variable

Form1:

string Ed = \"\", En = \"\"; 

public string En1
{
    get { r         


        
7条回答
  •  广开言路
    2020-11-27 21:47

    If you describe value as static then you can access it directly in Form1 and you can access it from Form2 :

    static public string Text_;
        string PassedValue_=Form1.Text_;
    

提交回复
热议问题