开发者

Form Activate event is not firing

开发者 https://www.devze.com 2023-03-22 09:44 出处:网络
I am using VB.Net for my Windows application. I will open two child form from MDI. Both formswill open. Now if I will go from form1 to form2 then Activate event for form2 will not fire.

I am using VB.Net for my Windows application. I will open two child form from MDI. Both forms will open. Now if I will go from form1 to form2 then Activate event for form2 will not fire. I dont know why this happen. Can 开发者_JAVA技巧any one help me out?


this.Deactivate += new EventHandler(Form1_Deactivate);
this.Activated += new EventHandler(Form1_Activated);

Try those eventhandlers (C#, should be similar in VB).

Tipp: You can also ask for the FormWindowState eg.:

if (FormWindowState.Normal == WindowState)
0

精彩评论

暂无评论...
验证码 换一张
取 消