By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,215 Members | 1,941 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,215 IT Pros & Developers. It's quick & easy.

MCISendString

P: n/a
I am trying to use the Notify Flag to send a message when a song is finished
playing. I got it to work by setting up a dummy window and overriding it's
WndProc procedure then raising an event in my application. This work great
until I open a new window then the Notify message doesn't seem to trigger the
WinProc procedure in my dummy window. I guess it's because another window
has the focus...is there any other way I can intercept this message when the
window or it's parent doesn't have the focus?

Dennis in Houston
Nov 21 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
I got it to work. The sample code I was using had poorly constructed dispose
methods and it was hanging up. Just one question though, if I have a routine
like MciSendString that notifies a window when it's done by sending a message
that window's handle and that window does not have the focus, will it still
receive the message or will the message be qued until the window gets the
focus?
--
Dennis in Houston
"Dennis" wrote:
I am trying to use the Notify Flag to send a message when a song is finished
playing. I got it to work by setting up a dummy window and overriding it's
WndProc procedure then raising an event in my application. This work great
until I open a new window then the Notify message doesn't seem to trigger the
WinProc procedure in my dummy window. I guess it's because another window
has the focus...is there any other way I can intercept this message when the
window or it's parent doesn't have the focus?

Dennis in Houston

Nov 21 '05 #2

P: n/a
>notifies a window when it's done by sending a message
that window's handle and that window does not have the focus, will it still
receive the message
Yes.

or will the message be qued until the window gets the focus?


The message is still queued, but when it will be retrieved from the
queue doesn't have anything to do with whether or not the window has
focus.

Mattias

--
Mattias Sjögren [MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
Nov 21 '05 #3

P: n/a
Thanks. It seems to work that way but I wanted a "second" opinion from
someone before I based my application design on this. Thanks again.
--
Dennis in Houston
"Mattias Sjögren" wrote:
notifies a window when it's done by sending a message
that window's handle and that window does not have the focus, will it still
receive the message


Yes.

or will the message be qued until the window gets the focus?


The message is still queued, but when it will be retrieved from the
queue doesn't have anything to do with whether or not the window has
focus.

Mattias

--
Mattias Sjögren [MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.

Nov 21 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.