在 Visual Basic 中单击按钮重新打开当前窗体
Re-Open current Form on button click in visual basic
我正在使用 VB.Net 开发应用程序。
有什么方法可以在点击按钮时打开当前表单。假设我在 Form1 中,如果用户单击按钮 "No",则应用程序应再次打开 Form1,否则如果答案为 "Yes",则应打开 Form2。我怎样才能让它再次打开相同的表格 (Form1)?
提前致谢。
创建 Form1 和 Form2 的新实例,
然后在条件语句中处理
'No Button
Dim f1 = new Form1();
f1.show();
Me.close();
'Yes Button
Dim f2 = new Form2();
f2.show();
Me.close();
我正在使用 VB.Net 开发应用程序。
有什么方法可以在点击按钮时打开当前表单。假设我在 Form1 中,如果用户单击按钮 "No",则应用程序应再次打开 Form1,否则如果答案为 "Yes",则应打开 Form2。我怎样才能让它再次打开相同的表格 (Form1)?
提前致谢。
创建 Form1 和 Form2 的新实例, 然后在条件语句中处理
'No Button
Dim f1 = new Form1();
f1.show();
Me.close();
'Yes Button
Dim f2 = new Form2();
f2.show();
Me.close();