110,536
社区成员
发帖
与我相关
我的任务
分享
public class Static
{
public static Form2 f2 = new Form2();
public static string txt = "";
public static bool isshow = false;
}
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
Static.isshow = true;
Thread td = new Thread(new ThreadStart(Shows));
td.Start();
}
private void Shows()
{
while (Static.isshow)
{
Static.f2.Show();
}
}
}