Re: Something like "ping" for windows messages.
- From: "Ajay Kalra" <ajaykalra@xxxxxxxxx>
- Date: Fri, 8 Dec 2006 08:25:28 -0500
"Peter Smithson" <Peter_Smithson@xxxxxxxxxxx> wrote in message
news:1165575066.102790.117730@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi,
I'm pretty new to Windows messaging.
I want to measure how responsive my application is to messages. I
thought about doing a SetTimer(1000) and measuring how near to a 1
second interval the WM_TIMER message is processed. Then average it out
over 10 messages and log it.
Then I thought there might already be a tool that runs as an external
process and sends some standard message and measures how quick a
response is recieved. The equivalent of "ping" in network terms.
Is there such a thing?
Otherwise, I'll write a little app to send a message to my application.
Better that it's something external than built in to the application
(as I can re-use it and don't have to complicate the apps
configuration).
What do you want to achieve by it. It all depends upon if you window
procedure is busy at the time when you send the message. If its waiting in a
loop then it will receive the message immediately. Alternatively, if its
busy doing some task (some long computation), it will receive the message
until the task is complete. If you send the message using SendMessage and
the window is busy, your app(the one sending the message) would appear hung.
You can use PostMessage as well which will queue the message. You should
also look at using SendMessageTimeout.
I am not aware of a tool which does this as I dont know what exactly you
achieve by doing this.
--
Ajay Kalra [MVP - VC++]
ajaykalra@xxxxxxxxx
.
- Follow-Ups:
- Re: Something like "ping" for windows messages.
- From: Peter Smithson
- Re: Something like "ping" for windows messages.
- References:
- Something like "ping" for windows messages.
- From: Peter Smithson
- Something like "ping" for windows messages.
- Prev by Date: Which macro we used in the MessageMap for user defined function
- Next by Date: Re: In Visual Studio 2005 how to convert TCHAR to CString?
- Previous by thread: Re: Something like "ping" for windows messages.
- Next by thread: Re: Something like "ping" for windows messages.
- Index(es):
Relevant Pages
|
Loading