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. Buttons problem.

Buttons problem.

Scheduled Pinned Locked Moved C / C++ / MFC
helpc++graphics
6 Posts 4 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.
  • L Offline
    L Offline
    Le rner
    wrote on last edited by
    #1

    Hi all, i m new in vc++2005. i load a bitmap or icon on button. i want when mouse indicate on purticular button then name of button show. like on webpage when we indicate on stop button then it shows STOP on mouse tail in yellow box,or same in case of refresh..etc. i dont know how can do it. please help me for this. Thanks in advance.

    R J G 3 Replies Last reply
    0
    • L Le rner

      Hi all, i m new in vc++2005. i load a bitmap or icon on button. i want when mouse indicate on purticular button then name of button show. like on webpage when we indicate on stop button then it shows STOP on mouse tail in yellow box,or same in case of refresh..etc. i dont know how can do it. please help me for this. Thanks in advance.

      R Offline
      R Offline
      rp_suman
      wrote on last edited by
      #2

      Hi, You can use Tool tip control[^] An example here: Button with ToolTip and/or bitmap resource[^] Best Regards, Suman

      L 1 Reply Last reply
      0
      • L Le rner

        Hi all, i m new in vc++2005. i load a bitmap or icon on button. i want when mouse indicate on purticular button then name of button show. like on webpage when we indicate on stop button then it shows STOP on mouse tail in yellow box,or same in case of refresh..etc. i dont know how can do it. please help me for this. Thanks in advance.

        J Offline
        J Offline
        James R Twine
        wrote on last edited by
        #3

        3 easy steps:      1: Use the TrackMouseEvent(...) on the controls in question or capture mouse movement messages to see when the mouse is over the control.      2: When the time is right, use the ToolTip control to cause an immediate tooltip to appear.      3: When the mouse moves off of the control, pop the tooltip.    1 easier step:      1: Use the tooltip control - it was designed for this kind of thing.  Check the docs for the tooltip control.    Peace!

        -=- James
        Please rate this message - let me know if I helped or not! * * * If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
        Remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
        See DeleteFXPFiles

        1 Reply Last reply
        0
        • R rp_suman

          Hi, You can use Tool tip control[^] An example here: Button with ToolTip and/or bitmap resource[^] Best Regards, Suman

          L Offline
          L Offline
          Le rner
          wrote on last edited by
          #4

          thanks i chekout this but there is an error "'static_cast' : cannot convert from 'void (__thiscall CToolTipRessourceButton::* )(WPARAM,LPARAM)' to 'LRESULT (__thiscall CWnd::* )(WPARAM,LPARAM)'" please help me.

          R 1 Reply Last reply
          0
          • L Le rner

            thanks i chekout this but there is an error "'static_cast' : cannot convert from 'void (__thiscall CToolTipRessourceButton::* )(WPARAM,LPARAM)' to 'LRESULT (__thiscall CWnd::* )(WPARAM,LPARAM)'" please help me.

            R Offline
            R Offline
            rp_suman
            wrote on last edited by
            #5

            Hi, When the error is happening? You tried which? Please provide more info. As James R. Twine said, try adding TrackMouseEvent() handler for your button and show the Tooltip control inside that function. If you have problems, please let us know. Best Regards, Suman

            1 Reply Last reply
            0
            • L Le rner

              Hi all, i m new in vc++2005. i load a bitmap or icon on button. i want when mouse indicate on purticular button then name of button show. like on webpage when we indicate on stop button then it shows STOP on mouse tail in yellow box,or same in case of refresh..etc. i dont know how can do it. please help me for this. Thanks in advance.

              G Offline
              G Offline
              GauranG Shah
              wrote on last edited by
              #6

              It think you are talking about the tool tip. Use the following class to show that tool tip. http://www.codeproject.com/KB/cpp/Tool_Tip.aspx[^]

              [ Screen Capture ][ Tool Tip ][ Muliple Desktops ][Greeting Card ]

              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