>From my main form, I can open and access a modeless form. However, if I
then open a modal form (from the main form), the modeless form will no
longer accept keyboard and mouse input until the modal form is closed.

Is there a way to allow the modeless form to continue to receive input?

As an example, Windows Notepad does this. If you open the Find dialog,
then open the About box, you can still access the Find dialog.

Any pointers appreciated.

Thanks,
Andrew

Re: How can I make a modeless form receive input when a modal form is open? by WineNCheese

WineNCheese
Wed May 10 19:10:24 CDT 2006

Perhaps a second thread?

<amacd@hotmail.com> wrote in message
news:1147292864.605281.141120@j73g2000cwa.googlegroups.com...
> >From my main form, I can open and access a modeless form. However, if I
> then open a modal form (from the main form), the modeless form will no
> longer accept keyboard and mouse input until the modal form is closed.
>
> Is there a way to allow the modeless form to continue to receive input?
>
> As an example, Windows Notepad does this. If you open the Find dialog,
> then open the About box, you can still access the Find dialog.
>
> Any pointers appreciated.
>
> Thanks,
> Andrew
>



Re: How can I make a modeless form receive input when a modal form is open? by Otis

Otis
Wed May 10 19:58:02 CDT 2006

On 10 May 2006 13:27:44 -0700, amacd@hotmail.com wrote:

>>From my main form, I can open and access a modeless form. However, if I
>then open a modal form (from the main form), the modeless form will no
>longer accept keyboard and mouse input until the modal form is closed.
>
>Is there a way to allow the modeless form to continue to receive input?
>
>As an example, Windows Notepad does this. If you open the Find dialog,
>then open the About box, you can still access the Find dialog.
>
>Any pointers appreciated.
>
>Thanks,
>Andrew

It works in Notepad because both forms are Modeless. A form can look like a
dialog without being Modeless. Set your Model from to Modeless and set the
FormBorderStyle to FixedDialog and open it with Show, instead of ShowDialog.

Good luck with your project,

Otis Mukinfus
http://www.arltex.com
http://www.tomchilders.com

Re: How can I make a modeless form receive input when a modal form is open? by amacd

amacd
Thu May 11 12:12:43 CDT 2006

WineNCheese wrote:
> Perhaps a second thread?

Yes, that does work. Unfortunately, the modeless form interacts a fair
bit with the main form, so multithreading would add code complexity I'd
prefer to avoid.

Perhaps someone knows how Microsoft Notepad does it? Could the "Find"
window be running in a separate thread from the main window, or is
there a simpler explanation?

Andrew


>
> <amacd@hotmail.com> wrote in message
> news:1147292864.605281.141120@j73g2000cwa.googlegroups.com...
> > >From my main form, I can open and access a modeless form. However, if I
> > then open a modal form (from the main form), the modeless form will no
> > longer accept keyboard and mouse input until the modal form is closed.
> >
> > Is there a way to allow the modeless form to continue to receive input?
> >
> > As an example, Windows Notepad does this. If you open the Find dialog,
> > then open the About box, you can still access the Find dialog.
> >
> > Any pointers appreciated.
> >
> > Thanks,
> > Andrew
> >


Re: How can I make a modeless form receive input when a modal form is open? by amacd

amacd
Thu May 11 12:19:12 CDT 2006

Otis Mukinfus wrote:
> On 10 May 2006 13:27:44 -0700, amacd@hotmail.com wrote:
>
> >>From my main form, I can open and access a modeless form. However, if I
> >then open a modal form (from the main form), the modeless form will no
> >longer accept keyboard and mouse input until the modal form is closed.
> >
> >Is there a way to allow the modeless form to continue to receive input?
> >
> >As an example, Windows Notepad does this. If you open the Find dialog,
> >then open the About box, you can still access the Find dialog.
> >
> >Any pointers appreciated.
> >
> >Thanks,
> >Andrew
>
> It works in Notepad because both forms are Modeless. A form can look like a
> dialog without being Modeless. Set your Model from to Modeless and set the
> FormBorderStyle to FixedDialog and open it with Show, instead of ShowDialog.

I tried your suggestion, but the (previously modal) form operates like
a normal modeless form with those changes. That is, I can still access
the main form.

That isn't the case with Notepad, which prevents access to the main
window when the About Box is open.

As another example, the "Find" window is also still accessible when the
(apparently) modal "File Open" message box is open.

Andrew



>
> Good luck with your project,
>
> Otis Mukinfus
> http://www.arltex.com
> http://www.tomchilders.com


Re: How can I make a modeless form receive input when a modal form is open? by Otis

Otis
Thu May 11 19:07:15 CDT 2006

On 11 May 2006 10:19:12 -0700, amacd@hotmail.com wrote:

>I tried your suggestion, but the (previously modal) form operates like
>a normal modeless form with those changes. That is, I can still access
>the main form.
>
>That isn't the case with Notepad, which prevents access to the main
>window when the About Box is open.
>
>As another example, the "Find" window is also still accessible when the
>(apparently) modal "File Open" message box is open.
>
>Andrew

To quote you in your previous post: "As an example, Windows Notepad does this."

Did you not know you can still access Notepad while the Modeless Find dialog is
open?

Sorry I thought you wanted it to work like Notepad.
Good luck with your project,

Otis Mukinfus
http://www.arltex.com
http://www.tomchilders.com

Re: How can I make a modeless form receive input when a modal form is open? by Otis

Otis
Thu May 11 19:11:56 CDT 2006

On 11 May 2006 10:19:12 -0700, amacd@hotmail.com wrote:

[snip]
>> It works in Notepad because both forms are Modeless. A form can look like a
>> dialog without being Modeless. Set your Model from to Modeless and set the
>> FormBorderStyle to FixedDialog and open it with Show, instead of ShowDialog.
>
>I tried your suggestion, but the (previously modal) form operates like
>a normal modeless form with those changes. That is, I can still access
>the main form.
>
>That isn't the case with Notepad, which prevents access to the main
>window when the About Box is open.
>
>As another example, the "Find" window is also still accessible when the
>(apparently) modal "File Open" message box is open.
>
>Andrew

Oops! I didn't read your example clearly. Sorry.
Good luck with your project,

Otis Mukinfus
http://www.arltex.com
http://www.tomchilders.com