当前位置: 首页 > 图文教程 > 网络编程 > ASP.NET > 如何制作一个带启动屏幕的窗体

ASP.NET
Web服务器控件:LinkButton控件
Web服务器控件:ListBox控件
Web服务器控件:ListItem控件
Web服务器控件:Literal控件
Web服务器控件:Panel控件
Web服务器控件:PlaceHolder控件
Web服务器控件:RadioButton控件
Web服务器控件:RadioButtonList控件
Web服务器控件:BulletedList控件
Web服务器控件:Style控件
Web服务器控件:Table控件
Web服务器控件:TableCell控件
Web服务器控件:TableRow控件
Web服务器控件:TextBox控件
Web服务器控件:XML控件
Validation服务器控件:CompareValidator控件
Validation服务器控件:CustomValidator控件
Validation服务器控件:RangeValidator控件
Validation服务器控件:RegularExpressionValidator控件
Validation服务器控件:RequiredFieldValidator控件

ASP.NET 中的 如何制作一个带启动屏幕的窗体


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-11-03   浏览: 140 ::
收藏到网摘: n/a


需要你准备两个Winform的窗体,一个叫它:SplashScreen,把它做成一个漂亮的窗体。然后你需要一个主窗体叫它:Form1吧,然后在这个窗体加入下面的代码。
// ( C# )
protected override void OnLoad ( System.EventArgs e )
{
//make load take a long time
Thread.Sleep(2000);
base.OnLoad(e);
}
然后在Main中加入这样的代码:
[STAThread]
static void Main()
{
SplashScreen splashForm = new SplashScreen();
splashForm.Show();
Form1 mainForm = new Form1() ;
mainForm.Load += new EventHandler(splashForm.MainScreen_Load);
Application.Run(mainForm);
}
不要忘了加上对Threading的引用: using System.Threading;