Custom Command Routing :: MFC

This is a discussion on Custom Command Routing :: MFC within the Windows Programming forums, part of the Platform Specific Boards category; Hi. Microsoft offers an impressive feature in MFC that routes WM_COMMAND and COMMAND_UPDATE messages via command routering using OnCmdMsg(...) in ...

  1. #1
    Registered User
    Join Date
    Nov 2001
    Posts
    1,348

    Custom Command Routing :: MFC

    Hi.

    Microsoft offers an impressive feature in MFC that routes WM_COMMAND and COMMAND_UPDATE messages via command routering using OnCmdMsg(...) in main and a function in doc to traverse through all active view. The drawback, however, is that it only works for COMMAND messages, not any messages.

    I wonder if there is a technique similar to the one mentioned above for specific command type such as user commanders (WM_USER_MYCOMMAND, etc). The message map would look like this:

    // ON_MESSAGE(WM_USER_MYCOMMAND, OnMyCommand)

    Thanks,
    Kuphryn

  2. #2
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Posts
    5,789
    SendMessage()

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. custom message map in MFC
    By bonkey in forum Windows Programming
    Replies: 2
    Last Post: 09-24-2003, 02:53 PM
  2. WIndows programming?
    By hostensteffa in forum Windows Programming
    Replies: 7
    Last Post: 06-07-2002, 09:52 PM
  3. Replies: 1
    Last Post: 05-24-2002, 12:19 AM
  4. Release MFC Programs & Dynamic MFC DLL :: MFC
    By kuphryn in forum Windows Programming
    Replies: 2
    Last Post: 05-18-2002, 07:42 PM
  5. Beginning MFC (Prosise) Part III - Now What? :: C++
    By kuphryn in forum C++ Programming
    Replies: 5
    Last Post: 03-03-2002, 06:58 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21