private void btnGetName_Click(object sender, EventArgs e) { dlgName dialog = new dlgName(); dialog.penguinName = "Type your penguin's name..."; DialogResult dr = dialog.ShowDialog(); if(dr==DialogResult.OK) { lblName.Text = dialog.penguinName; } }
private void btnGetName_Click(object sender, EventArgs e) { dlgName dialog = new dlgName(); dialog.penguinName = "Type your penguin's name..."; DialogResult dr = dialog.ShowDialog(); if (dr == DialogResult.OK) { lblName.Text = dialog.penguinName; } }