How to detect if New Message window is open?

  • Thread starter Thread starter michaaal
  • Start date Start date
M

michaaal

I want to do something like this...

If OpenNewMessageWindow="yes" then
msgbox ("The new message window is open")
Else
msgbox ("The new message window is not open")
End If

I know my code isn't right. Could someone lead me in the right direction?
Thanks.
 
The Application.Inspectors collection contains all the open item windows,
including any for new messages. You could loop through that collection,
examine each Inspector.CurrentObject object to see if it's a new message. In
a new message, the Sent property will be False.
 
Back
Top