PC Review


Reply
Thread Tools Rate Thread

How to block a switch to other forms in appl when a modal form is

 
 
=?Utf-8?B?U2FuZHk=?=
Guest
Posts: n/a
 
      15th Nov 2005
Hi all,
I have an application where I have these forms:
- main form/window of the appl
- a modeless form, with ShowInTaskBar=true
- a modal form launched from this modeless form.

When this modal form is launched from modeless,the whole application is
locked. This is fine.
As I have launched this modal from a modeless form that has ShowInTaskBar
set to true I get 2 windows listed on taskbar and I can switch to main
application window (though I can't do anything there).
If I set ShowInTaskBar=false for the modeless form I get just one window
(main appl window) on taskbar and switching to it takes me to the modal form.
But my requirement is such that I cant do away with ShowInTaskBar.

My problem is that I need some way out to force user back on the modal when
he tries to switch to the main window. Something similar to what Outlook (I
checked with Outlook 2003) does.
I can try getting it using some crude way, but I want to make sure I am not
missing some standard way out and use the best suitable apis.

Can someone help?


-Sandy
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
switch focus between modal forms? Ed White Microsoft Dot NET Framework Forms 5 2nd Feb 2009 09:47 PM
Modal Forms and the Form Load event =?Utf-8?B?VGVycnk=?= Microsoft VB .NET 0 6th Nov 2007 10:07 PM
Periodic problem in InitializeComponent of modal form with a forms.timer Stephen Rice Microsoft VB .NET 9 23rd Jan 2007 08:39 PM
Multiple Modeless forms, each with a Modal child form. =?Utf-8?B?am5pY2s=?= Microsoft Dot NET Framework Forms 0 24th Feb 2006 03:38 PM
How to block a switch to other forms in appl when a modal form is =?Utf-8?B?U2FuZHk=?= Microsoft Dot NET Framework Forms 0 15th Nov 2005 09:57 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:16 AM.