how/what dialog boxes can I display from VBA code

M

masani paresh

Hi,

I am using messagebox in my VBA macro. The MessageBox seems to not working
as it doesn't get focused me until I activate my Outlook window.

I also want to keep adding messages like "XXX", "YYYY" in same dialog box.
Basically I am looking for similar dialog og "New Alert Item" that outlook
support.

Could you please suggest how/what dialog box that I can display from VBA code?

Please let me know if you have any questions.
 
K

Ken Slovak - [MVP - Outlook]

MsgBox is modal, you can't add to it after it's displayed, and the code
won't proceed until the user dismisses the message box.

You can use a VBA UserForm, displayed non-modally to show text and add to it
when you want. But that won't have the transparency or timed removal you
have with the new message toast window that Outlook shows.

There are 3rd party controls you can purchase that you can set transparency
on and you can call and dismiss them based on a timer control, but that's
not really appropriate for VBA code.

I'd just probably stick with a UserForm since this is VBA code. Anything
else would be very complex to implement.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top