如何实施表单加载完成事件 [英] How to Implement form Load Complete event

查看:311
本文介绍了如何实施表单加载完成事件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在c#中实现表单加载完成事件????
我的Windows应用程序需要花费一些时间来加载表单.
因此,只要加载事件结束,
应该调用Load_Complete事件.

在此先感谢

How to Implement form Load Complete event in c# ???
My windows application takes time to load form.
So whenever load event is finished
Load_Complete event should called.

Thanks in advance

推荐答案

还有另一个可以处理的事件:Form.Shown.

Form.Load事件发生后,当实际显示您的Form时会触发此事件.

最近有一篇关于此的文章:

使用Shown()事件立即显示WinForms [
There is another event that you can handle: Form.Shown.

This is fired when your Form is actually shown, well after the Form.Load event.

There is a recent article about this here:

Immediate display of WinForms using the Shown() event[^]

Nick


该表单将在Load事件的事件处理程序的末尾完全加载.
The form will be completely loaded at the end of the event handler for the Load event.


就像aspdotnetdev所说的那样,您可以调用该函数您想要在加载事件功能结束时
like what aspdotnetdev said you can call the function you want in the end of loading event function


这篇关于如何实施表单加载完成事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆