Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. "Add Event Handler" greyed out in VS2005

"Add Event Handler" greyed out in VS2005

Scheduled Pinned Locked Moved C / C++ / MFC
questionlearning
8 Posts 5 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    flippydeflippydebop
    wrote on last edited by
    #1

    Hey there. Can anybody tell me why, when you create a dialog app in VS2005 if you right-mouse click on the dialog in the resource editor then "Add Event Handler" menu option is greyed out? I want to be able to add OnInitDialog and OnPaint handlers to this dialog but cant! If i drop a button control on the dialog through, and right click on that, then that works!! thanks in advance.

    realJSOPR 1 Reply Last reply
    0
    • F flippydeflippydebop

      Hey there. Can anybody tell me why, when you create a dialog app in VS2005 if you right-mouse click on the dialog in the resource editor then "Add Event Handler" menu option is greyed out? I want to be able to add OnInitDialog and OnPaint handlers to this dialog but cant! If i drop a button control on the dialog through, and right click on that, then that works!! thanks in advance.

      realJSOPR Offline
      realJSOPR Offline
      realJSOP
      wrote on last edited by
      #2

      To add non-control message handlers, you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane. At that point you hould be able to add the handler for that message.

      "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
      -----
      "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

      S F J J 4 Replies Last reply
      0
      • realJSOPR realJSOP

        To add non-control message handlers, you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane. At that point you hould be able to add the handler for that message.

        "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
        -----
        "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

        S Offline
        S Offline
        S Douglas
        wrote on last edited by
        #3

        John Simmons / outlaw programmer wrote:

        To add non-control message handlers, you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane. At that point you hould be able to add the handler for that message.

        [sarcasm] Clearly that's so much easier than VS6[/sarcasm] Thanks for the tip, not that I will remember it, just seams easier to write it out.


        realJSOPR 1 Reply Last reply
        0
        • realJSOPR realJSOP

          To add non-control message handlers, you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane. At that point you hould be able to add the handler for that message.

          "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
          -----
          "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

          F Offline
          F Offline
          flippydeflippydebop
          wrote on last edited by
          #4

          Hey John! No way, i would have never have found that out.. Thanks a million.. :) It all becomes clear (as mud!)

          1 Reply Last reply
          0
          • realJSOPR realJSOP

            To add non-control message handlers, you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane. At that point you hould be able to add the handler for that message.

            "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
            -----
            "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

            J Offline
            J Offline
            Jorgen Sigvardsson
            wrote on last edited by
            #5

            :omfg:

            -- Now with chucklelin

            1 Reply Last reply
            0
            • realJSOPR realJSOP

              To add non-control message handlers, you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane. At that point you hould be able to add the handler for that message.

              "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
              -----
              "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

              J Offline
              J Offline
              JudyL_MD
              wrote on last edited by
              #6

              John Simmons / outlaw programmer wrote:

              you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane.

              You can also just click anywhere within the class definition in the .h file, and then go to the properties pane.

              realJSOPR 1 Reply Last reply
              0
              • S S Douglas

                John Simmons / outlaw programmer wrote:

                To add non-control message handlers, you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane. At that point you hould be able to add the handler for that message.

                [sarcasm] Clearly that's so much easier than VS6[/sarcasm] Thanks for the tip, not that I will remember it, just seams easier to write it out.


                realJSOPR Offline
                realJSOPR Offline
                realJSOP
                wrote on last edited by
                #7

                Yeah... :) This goes a long way to reinforce Microsoft's claim that they are eager to support their C++ developers. The 2005 IDE sucks if you're a MFC programmer. I seriously doubt that ORCAS would add any usability for us...

                "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                -----
                "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

                1 Reply Last reply
                0
                • J JudyL_MD

                  John Simmons / outlaw programmer wrote:

                  you have to go to the source file, and place the cursor on the closing message map macro, and then go to the properties pane.

                  You can also just click anywhere within the class definition in the .h file, and then go to the properties pane.

                  realJSOPR Offline
                  realJSOPR Offline
                  realJSOP
                  wrote on last edited by
                  #8

                  That doesn't always work. In fact, neither does my original response.

                  "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                  -----
                  "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001

                  1 Reply Last reply
                  0
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  • Login

                  • Don't have an account? Register

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • World
                  • Users
                  • Groups