简单的启动窗体
更新时间:2006年10月26日 00:00:00 作者:
复制代码 代码如下:
public static System.Threading.Thread thread;
public static ce.About welcomefrm;
[STAThread]
static void Main()
{
System.Threading.ThreadStart start=new ThreadStart(ce.ceStart.splashForm);
thread=new Thread(start);
thread.Start();
//做要做的事
//运行主程序
System.Windows.Forms.Application.Run(new ce.Forms.coolmain());
}
static void splashForm()
{
ce.ceStart.welcomefrm =new About();
ce.ceStart.welcomefrm.Show();
Application.DoEvents();
ce.ceStart.welcomefrm.Activate();
thread.Join(2000);
ce.ceStart.welcomefrm.Close();
ce.ceStart.thread.Abort();
}
public static ce.About welcomefrm;
[STAThread]
static void Main()
{
System.Threading.ThreadStart start=new ThreadStart(ce.ceStart.splashForm);
thread=new Thread(start);
thread.Start();
//做要做的事
//运行主程序
System.Windows.Forms.Application.Run(new ce.Forms.coolmain());
}
static void splashForm()
{
ce.ceStart.welcomefrm =new About();
ce.ceStart.welcomefrm.Show();
Application.DoEvents();
ce.ceStart.welcomefrm.Activate();
thread.Join(2000);
ce.ceStart.welcomefrm.Close();
ce.ceStart.thread.Abort();
}
相关文章
WPF框架Prism中ViewModelLocator用法介绍
这篇文章介绍了WPF框架Prism中ViewModelLocator的用法,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面随着小编来一起学习学习吧2022-02-02
最新评论