Bijvoorbaad dank.
Marcel.
Dit is de oplossing van John Walkenbach van 25 April 2001:
>Excel can access the Windows Scripting Host (Wscript), and display
another
>type of message box by using the Popup method of the Shell object. This
>alternative message box differs from the standard message box in two
ways:
>it can dismiss itself after a specified period of time, and it's
possible to
>display the message box with no buttons.
>
>The example below displays a message box. If the user does not dismiss
it
>within five seconds, it is dismissed automatically.
>
>Sub PopupDemo()
> Dim WshShell As IWshShell
> Dim Msg As String
> Set WshShell = CreateObject("Wscript.Shell")
> Msg = "This message will self-destruct in 5 seconds."
> Title = "A friendly reminder"
> WshShell.Popup Msg, 5, Title, 7 + vbInformation
> Set WshShell = Nothing
>End Sub
>
>The first Set statement creates the Shell object, and assigns it to the
>WshShell variable. The first argument for the Popup method respresents
the
>text to be displayed. The second argument specifies the number of
seconds to
>display the message box. The third argument is the title bar text. The
final
>argument specifies the buttons and icon to be displayed (it works just
like
>the buttons argument for the MsgBox function).
>
>If you decide to use this alternate message box, be aware that system
>adminstrators often disable the Windows Scripting Host because of the
threat
>of viruses. If the Windows Scripting Host is disabled, the code will
>generate an error.
>
>Another alternative is to use a UserForm that dismisses itself. You'll
find
>an example here:
>
>http://j-walk.com/ss/excel/tips/tip39.htm
>
>John Walkenbach
>For Excel tips, macros, & downloads...
>http://j-walk.com/ss
Groet,
Roland