Re: To MsgBox, or not to MsgBox
From: J French (erewhon_at_nowhere.com)
Date: 03/27/04
- Next message: dilish: "Re: A problem while exporting to Excel - URGENT please"
- Previous message: Ayaz Ahmed: "Re: combobox"
- In reply to: Tony Proctor: "To MsgBox, or not to MsgBox"
- Next in thread: Tony Proctor: "Re: To MsgBox, or not to MsgBox"
- Reply: Tony Proctor: "Re: To MsgBox, or not to MsgBox"
- Messages sorted by: [ date ] [ thread ]
Date: Sat, 27 Mar 2004 12:10:04 +0000 (UTC)
On Sat, 27 Mar 2004 10:32:45 -0000, "Tony Proctor"
<tony_proctor@aimtechnology_NOSPAM.com> wrote:
>Does anyone know of a test that will indicate whether a MsgBox call is
>legal, i.e. whether the current process/thread has access to a UI
>
>Some situations (e.g. services, IIS, silent installs over a reboot) will
>result in a hang if MsgBox is called. I accept the argument that such code
>should not use MsgBox, but this is a common component and it's not actually
>my "call".
In the cases you are thinking of, by 'hang' do you mean stick an
semi-ownerless MessageBox on the screen, or something nastier ?
Even a Console Mode App can generate a MessageBox
This silly little demo might give you some ideas :-
Sub Main()
App.TaskVisible = False
If App.UnattendedApp Then
MsgBox "Wha Hay" + Str$(App.TaskVisible)
End If
End Sub
- Next message: dilish: "Re: A problem while exporting to Excel - URGENT please"
- Previous message: Ayaz Ahmed: "Re: combobox"
- In reply to: Tony Proctor: "To MsgBox, or not to MsgBox"
- Next in thread: Tony Proctor: "Re: To MsgBox, or not to MsgBox"
- Reply: Tony Proctor: "Re: To MsgBox, or not to MsgBox"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|