Passing Variable from one form to another form in windows application:
In first form Under Button click wirte like this
private void button1_Click(object sender, EventArgs e)
{
Display d = new Display(textBox1 .Text );
d.Show();
}
Then In secound Form write like this
public partial class Display : Form
{
string str;
public Display(string txt)
{
InitializeComponent();
str = txt;
}
private void Display_Load(object sender, EventArgs e)
{
label1.Text = str;
}
}