5
A
回答
6
Here is a nice example.如果您使用的是Windows窗体。
3
(我在我的Mac,所以我现在可能有点生疏...)
你需要打开你的项目的偏好。
项目 - >首选项
在第一个选项卡,选择有所谓的“启动对象”的下拉菜单。默认值是Form1.cs,你应该可以将其更改为启动画面窗口。
2
添加对Microsoft.VisualBasic的引用。然后在Program.cs中编写下面的代码
static class Program
{
static void Main(string[] args)
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
new MyApp().Run(args);
}
public class MyApp : WindowsFormsApplicationBase
{
protected override void OnCreateSplashScreen()
{
this.SplashScreen = new MySplashScreen();
}
protected override void OnCreateMainForm()
{
// Do stuff that requires time
System.Threading.Thread.Sleep(5000);
// Create the main form and the splash screen
// will automatically close at the end of the method
this.MainForm = new MyMainForm();
}
}
}
3
在Visual Studio 2010中,这非常简单。只需将图像添加到解决方案中,然后右键单击该图像,并将其构建操作设置为“SplashScreen”。
无需编码!
相关问题
- 1. 如何在eclipse中添加视频/实时启动画面?
- 2. 如何在ios的启动画面中添加.gif文件?
- 3. 如何在wp7中添加启动画面
- 4. 如何在启动画面中添加进度条pyqt4
- 5. 如何加快加载启动画面
- 6. 如何在vb.net的启动画面上添加图像
- 7. Ember JS实现启动画面/加载启动画面
- 8. 如何在我的iPhone应用程序中添加两个启动画面?
- 9. 如何在页面完全加载后才启动CSS动画?
- 10. WPF动画启动画面
- 11. 如何在tableView中添加动画Swift
- 12. 如何在自动启动时隐藏MFC启动画面?
- 13. 卡在Android Studio启动画面(启动画面)!
- 14. 如何在uboot中启用dm 365上的启动画面?
- 15. 如何在ios启动画面上实现mp4动画?
- 16. 在活动中包含启动画面
- 17. 如何在Excel启动时创建启动画面?
- 18. 如何仅在首次启动时使用启动画面?
- 19. 如何添加动画BottomSheetDialogFragment
- 20. 如何将启动画面加载视图直到其加载
- 21. j2me启动画面
- 22. jQuery启动画面
- 23. 在cocos2d中添加动画
- 24. C#启动加载页面
- 25. 启动画面的问题 - C# - VS2005
- 26. 如何编写启动画面?
- 27. 如何随机化启动画面?
- 28. 如何禁用SDL启动画面?
- 29. 如何关闭启动画面
- 30. 在libharu中动态添加页面C
@ n535 - 很好的例子。 – Moshe 2010-04-04 15:06:39