Mdichild表格没有得到关注 [英] Mdichild form does not receive focus

查看:57
本文介绍了Mdichild表格没有得到关注的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个MDI表单,其中包含一个树(左侧停靠),用作打开MDIChild表单的菜单。当我单击树的节点(在 NodeMouseClick 事件中)时,将打开一个新的MDIChild表单。问题是它没有得到关注。焦点总是留在树上。 MDIChild表单没有标题,并且在父MDI表单中最大化。



我尝试过:



我试过在MDIChild表格上使用.Focus,Activate,BringToFront而没有任何运气。



是否有解决方案这个问题?使用.NET 4.0.3。

解决方案

哇!经过近几天的大量搜索,我偶然发现了这一点:树控焦点沮丧| PC评论 [ ^ ]



最后一篇文章中的建议工作!



感谢所有人协助。

I have an MDI form which contains a tree (docked left) which acts as a menu for opening MDIChild forms. When i click on a node of the tree (in NodeMouseClick event), a new MDIChild form is opened. The problem is that it does not receive the focus. The focus always remains on the tree. The MDIChild form does not have a Title and is maximized within the parent MDI form.

What I have tried:

I have tried using .Focus, Activate, BringToFront on the MDIChild form without any luck.

Is there a solution to this problem? Using .NET 4.0.3.

解决方案

Wow! After a lot of searching in the last couple of days, i stumbled onto this: Tree control focus frustration | PC Review[^]

The proposal in the final post worked!

Thanks to everyone for the assistance.


这篇关于Mdichild表格没有得到关注的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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