Solved

event message handlers ?

Posted on 2004-03-30
4
205 Views
Last Modified: 2010-04-01
Hi,

   What is "event message handler" ? and how is it related to afx_msg ? Thanks !

meow.
0
Comment
Question by:meow00
4 Comments
 
LVL 14

Assisted Solution

by:wayside
wayside earned 50 total points
Comment Utility
An event message handler is a function that you write that gets calls in response to an input event by the user.

"afx_msg" is a convention used to identify those functions that are event handlers. It doesn't actually do anything.
0
 
LVL 15

Accepted Solution

by:
lakshman_ce earned 75 total points
Comment Utility
The afx_msg keyword suggests the effect of the C++ virtual keyword by distinguishing the handlers from other CWnd member functions. Note, however, that these functions are not actually virtual; they are instead implemented through message maps. Message maps depend solely on standard preprocessor macros, not on any extensions to the C++ language. The afx_msg keyword resolves to white space after preprocessing.

You can Read more at
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore98/html/_core_handlers_for_standard_windows_messages.asp

-Lakshman
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

This article will show you some of the more useful Standard Template Library (STL) algorithms through the use of working examples.  You will learn about how these algorithms fit into the STL architecture, how they work with STL containers, and why t…
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

744 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

8 Experts available now in Live!

Get 1:1 Help Now