How to get the ID of the Message Window opened with ComposeMessage()

6 views
Skip to first unread message

Marcelle

unread,
Jan 26, 2010, 3:32:35 AM1/26/10
to Nektra OEAPI Support
Hello,
I am using OEAPI version 3.2.3 and C++ on Windows Vista and Windows
Mail 6.0.
I open a new message window using ComposeMessage() and I want to get
the ID of the new Window using GetActiveMsgWndID():

m_oeapi->ComposeMessage();
long newMsgWndId = m_oeapi->GetActiveMsgWndID();

Instead of getting the ID of the new window I get the ID of the
message window of the currently selected message. But if I add the
Sleep() method to my code:

m_oeapi->ComposeMessage();
Sleep(500);
long newMsgWndId = m_oeapi->GetActiveMsgWndID();

I get the new window ID (the one I am looking for).
This solution doesn't satisfy me.
Is there another way to get the ID of the message window opened by
ComposeMessage()?

Regards,
Ewa Jajszczyk

Reply all
Reply to author
Forward
0 new messages