Board index » delphi » "Floating" dialogs over parents

"Floating" dialogs over parents

This is a simple question, one I know has an easy answer, but I'm
transitioning from VB/C++ to Delphi . . .

I'm trying to have an About box and an Options dialog appear over the
main form of an application, and while they're open, the main form cannot
be accessed.  Simple enough, but some of the Delphi fucntions and API
wrapping are throwing me off.

--
BADGER
(aka Steve Savage)
------------------------------------------------------------------
Badger's Den:
http://www.infinet.com/~badger

MEMBER OF:
Association of Internet Professionals: http://www.association.org/
Java Lobby: http://www.javalobby.com/
------------------------------------------------------------------

 

Re:"Floating" dialogs over parents


Quote
>This is a simple question, one I know has an easy answer, but I'm
>transitioning from VB/C++ to Delphi . . .

>I'm trying to have an About box and an Options dialog appear over the
>main form of an application, and while they're open, the main form cannot
>be accessed.  Simple enough, but some of the Delphi fucntions and API
>wrapping are throwing me off.

What? All of that Basic and C++ Windows programming and you've never
come across the word "modal"? I'm surprised...

(Look it up the the Delphi help file).
--
Jeremy Collins

Re:"Floating" dialogs over parents


Steven Savage schrieb in Nachricht <6bpk6e$...@news1.infinet.com>...

Quote
>This is a simple question, one I know has an easy answer, but I'm
>transitioning from VB/C++ to Delphi . . .

>I'm trying to have an About box and an Options dialog appear over the
>main form of an application, and while they're open, the main form
cannot
>be accessed.  Simple enough, but some of the Delphi fucntions and API
>wrapping are throwing me off.

If you show the form using Show, it will be over the app, but the app
will still react. If you use ShowModal, the control is entirely in the
form, so the app cannot react. Other apps can, however (at least in
Win32).

Re:"Floating" dialogs over parents


Steven Savage schrieb in Nachricht <6bpk6e$...@news1.infinet.com>...

Quote
>This is a simple question, one I know has an easy answer, but I'm
>transitioning from VB/C++ to Delphi . . .

>I'm trying to have an About box and an Options dialog appear over the
>main form of an application, and while they're open, the main form
cannot
>be accessed.  Simple enough, but some of the Delphi fucntions and API
>wrapping are throwing me off.

If you show the form using Show, it will be over the app, but the app
will still react. If you use ShowModal, the control is entirely in the
form, so the app cannot react. Other apps can, however (at least in
Win32).

Re:"Floating" dialogs over parents


Steven Savage schrieb in Nachricht <6bpk6e$...@news1.infinet.com>...

Quote
>This is a simple question, one I know has an easy answer, but I'm
>transitioning from VB/C++ to Delphi . . .

>I'm trying to have an About box and an Options dialog appear over the
>main form of an application, and while they're open, the main form
cannot
>be accessed.  Simple enough, but some of the Delphi fucntions and API
>wrapping are throwing me off.

If you show the form using Show, it will be over the app, but the app
will still react. If you use ShowModal, the control is entirely in the
form, so the app cannot react. Other apps can, however (at least in
Win32).

Re:"Floating" dialogs over parents


Steven Savage schrieb in Nachricht <6bpk6e$...@news1.infinet.com>...

Quote
>This is a simple question, one I know has an easy answer, but I'm
>transitioning from VB/C++ to Delphi . . .

>I'm trying to have an About box and an Options dialog appear over the
>main form of an application, and while they're open, the main form
cannot
>be accessed.  Simple enough, but some of the Delphi fucntions and API
>wrapping are throwing me off.

If you show the form using Show, it will be over the app, but the app
will still react. If you use ShowModal, the control is entirely in the
form, so the app cannot react. Other apps can, however (at least in
Win32).

Re:"Floating" dialogs over parents


Show command shows the window, showmodal shows the windows too but thet
application waites until you close that window. Afterwards the code further
on is executed...

Tomaz

Quote
Steven Savage wrote in message <6bpk6e$...@news1.infinet.com>...
>This is a simple question, one I know has an easy answer, but I'm
>transitioning from VB/C++ to Delphi . . .

>I'm trying to have an About box and an Options dialog appear over the
>main form of an application, and while they're open, the main form cannot
>be accessed.  Simple enough, but some of the Delphi fucntions and API
>wrapping are throwing me off.

>--
>BADGER
>(aka Steve Savage)
>------------------------------------------------------------------
>Badger's Den:
>http://www.infinet.com/~badger

>MEMBER OF:
>Association of Internet Professionals: http://www.association.org/
>Java Lobby: http://www.javalobby.com/
>------------------------------------------------------------------

Other Threads