private void button1_Click(object sender, EventArgs e) { Form2 f2 = new Form2(); //กำหนดตัวแปล f2 f2.Show(); //เปิดฟอร์ม2 }
private void Button1_Click(object sender, EventArgs e) { Form2 frm2 = new Form2(this); frm2.Show(); }
public void refresh() //เรียกใช้ method refresh { Form2 f2 = new Form2(); //รับค่าฟอร์มสอง f2.Show(); //เปิดฟอร์ม }