473,735 Members | 5,177 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Focus Problems with MDI child forms

Hi Folks,

Sorry if you have seen this post before - I've posted it before, but it
seems to have gotten lost in Outlook limbo - it's visible on the web
interface, but not in any news reader I've tried :S

A while ago, I came accross this post by Armin describing how to reporduce a
focus bug with MDI children. I am currently experiencing the same problem in
my application although I'm not using an ActiveX control directly on the
form as in Armin's example (my 3rd party toolbars and menus could be the
culprits though).

I'm using Visual Studio 2003 with .net 1.1 on Windows XP.

Any help would be greatly appreciated.

Trev.

Origional Post by Armin (edited) - see http://tinyurl.com/2ezw2 for
origional:
----------------------------------------------------------------------------
--
Problem: A child can not be activated anymore by clicking in its
client area. It can only be activated by clicking the title bar. Also
the title bar does not always have the expected color depending on
the focus. Is this a known bug? I googled and search MSFT KB but
didn't find anything. Steps to reproduce:
1. New WindowsApplicat ion
2. Add two new Forms (Form2 and Form3)
3. For Form1: Set IsMdiContainer= True
4. Add the following code to Form1:

Private Sub Form1_Load( _
ByVal sender As System.Object, _
ByVal e As System.EventArg s) _
Handles MyBase.Load

Dim f2 As New Form2
Dim f3 As New Form3
f2.MdiParent = Me
f2.Show()
f3.MdiParent = Me
f3.Show()
End Sub

5. On Form3, add an ActiveX control, e.g. WebBrowser (shdocvw.dll)
6. Start
Armin



Nov 22 '05 #1
2 2270
Cor
Hi Trev,

Is there a reason you did not include the newsgroup

microsoft.publi c.dotnet.langua ges.vb in it,

that is the group where Armin is the most active from the international
groups, but not in the ones you have included I thought.

And as far as I have seen in the newsgroup is Armin in the newsgroups one of
the real MDI experts.

If you even want to have more success you can ask it also in the German
language in the newsgroup

microsoft.de.ge rman.entwickler .dotnet.vb

Cor
Nov 22 '05 #2
Cor,

I didn't post it to the VB group because I thought it was a more generic
problem (hence the .windowsforms group). I added the .faq and .general
groups because I was having problems with the .windowsforms group and was
hoping for a better response. Surely someone else out there has come accross
this problem before? I'll do up a sample project and see if it is limited to
VB.
that is the group where Armin is the most active
Thanks for the tip about Armin's whereabouts ;) He's the one who posted the
original article a while back, but there was no responses to that. Next time
I see him in a group, I'll discretely OT the thread and ask him.
If you even want to have more success you
can ask it also in the German
language in the newsgroup
Unfortunately I can't speak German - only English, VB and passable C# ;)

Thanks again for the tip,

Trev.
"Cor" <no*@non.com> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. .. Hi Trev,

Is there a reason you did not include the newsgroup

microsoft.publi c.dotnet.langua ges.vb in it,

that is the group where Armin is the most active from the international
groups, but not in the ones you have included I thought.

And as far as I have seen in the newsgroup is Armin in the newsgroups one of the real MDI experts.

If you even want to have more success you can ask it also in the German
language in the newsgroup

microsoft.de.ge rman.entwickler .dotnet.vb

Cor

Nov 22 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
480
by: Trev Hunter | last post by:
Hi Folks, Sorry if you have seen this post before - I've posted it before, but it seems to have gotten lost in Outlook limbo - it's visible on the web interface, but not in any news reader I've tried :S A while ago, I came accross this post by Armin describing how to reporduce a focus bug with MDI children. I am currently experiencing the same problem in my application although I'm not using an ActiveX control directly on the form as...
1
3368
by: tdmailbox | last post by:
Is there a vb command that can tell me if I have focus in the child or parent form? Basicly I have a search macro that needs me to have focus to any field in the parent form. If my focus is set on any field in the parent form it will search that field. However if I have focus set to a field in the child form it fails. What I want to do is set focus to field1 of the parent table but ONLY if focus is on a field in the child form. Is...
2
7403
by: Mystery Man | last post by:
We have an MDI application that is not setting always setting focus to the newly corrected MDI. It is creating the form and it is the topmost but it does not have focus. The code we are using to activate the MDI is something like the following: frmTest frm = new frmTest(); frm.MdiParent = this; frm.Show();
13
2321
by: Mike L | last post by:
I have a child form frmDataEntry call up another child form frmDealerSearch. If the user clicks on cancel on frmDealerSearch, I want to close frmDealerSearch and put the focus on txtDealerNum on frmDataEntry. Here is my code. public class frmDataEntry : System.Windows.Forms.Form { private void txtDealerNum_Leave(object sender, System.EventArgs e) {
1
2898
by: Sumit | last post by:
Hi all, I have an MDI form in which i open some other forms. I dont want the Control Box (having minimize, restore/maximize and close button) Even though I have set the controlbox property of my child forms as false & the respective minimize & maximize box property to false, i get the control box with restore button as enabled (when i dock my child form in the MDI form with dockstyle as fill) which restores the
2
1426
by: Christian Ista | last post by:
Hello, I found that (see below) to give the focus to a control(textbox) on an asp.net page. There is no easiest way to do that ? Thanks, System.Text.StringBuilder sb = new System.Text.StringBuilder(""); sb.Append("<script language=\"JavaScript\">");
8
2003
by: copyco | last post by:
I want to be able to test if my app's form has focus, (ie: not in background, behind other windows). How can I do this? I tried the Me.Focused, but that doesn't work. I think it's because a control within the form actually has focus, so the Me.Focused would return false. Thanks!
0
1325
by: nomenklatura | last post by:
Hi, I have a main menu which parent mdi form and i opening two mdi child form (frm1,frm2) with listview doubleclick event on main menu.. ex: Dim frm As New frm1 frm.MdiParent = Me frm.Show()
4
4305
by: Jon Slaughter | last post by:
I've created some custom controls and forms that allow the feature to temporarily transfer focus to a control that has been entered by the mouse. Everything seems to work fine but the problem I have is that sometimes I seem to loose the original "holder" of focus and when the user hits tab while using "temporary" focus(while the mouse is over a control) it will change focus to the next control but not update it. So I have several issues....
5
3341
by: oscWork | last post by:
Does anyone know of any way to switch focus between a main form and a child form without the usual flickering you get while changing focus between windows? This works fine if the main form is an MDI container and the child form is within that container, but MDI is not appropriate for this application. I would like to be able to interact with a form without losing focus on the main form. Obvious workarounds such as setting focus on the main...
0
8962
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9200
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8201
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6049
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4559
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4822
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3273
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2739
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2188
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.