Solved

ON_THREAD_MESSAGE

Posted on 2000-02-24
2
1,339 Views
Last Modified: 2013-11-20
Hi,
I implemented a CWInThread derived class and I wanted to receive some asynchronous messages from other threads.

I used the MFC Macro ON_THREAD_MESSAGE on my code. Whats the meaning of the two arguments of the handler member function passed to by the framework (UINT, LONG)?

afx_msg void memberFxn(UINT, LONG)

Additionaly how can I retrieve the MSG inside this function?

Thanks,
Antonio Nogueira
0
Comment
Question by:nogueira
2 Comments
 
LVL 8

Accepted Solution

by:
VinExpert earned 100 total points
ID: 2554183
Hi,

They R WPARAM and LAPARAM values I beleive. So Ur function will be as

afx_msg void memberFxn(WPARAM wp, LPARAM lp) ;

They r used for any additional message information. For example U can post the thread message with the
message = whatever message u want to send
next parameter = WPARAM = some addition value which means something to U.

similarly the third parameter.

Hope this gives some ideas.
VinExpert
0
 

Author Comment

by:nogueira
ID: 2555256
thanks,
Vin
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This video discusses moving either the default database or any database to a new volume.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now