Outlook window to front

C

ChrisK

Hi all,

I'm using the following code snippet to create email in Outlook:

Dim appOutlook As Outlook.Application, msg As Outlook.MailItem
On Error GoTo ErrHandler:
Set appOutlook = GetObject(, "Outlook.Application")
Set msg = appOutlook.CreateItem(olMailItem)
With msg
.To = strTo
If strSubject <> "" Then .Subject = strSubject
If strBody <> "" Then .Body = strBody
.Display
End With

Is there a method to bring the Outlook mail item window to the front when
this sub is run?

CK
 

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