[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Tool Tips In Form Views

Posted on 1998-03-03
3
Medium Priority
?
602 Views
Last Modified: 2013-11-20
I have an app that uses a form view that contains buttons. I would like to provide tool tips for these buttons. This functionality it not wired in to the view class (it is in CFrameWnd derived classes). The online help outlines a procedure to accomplish this.
1. Call EnableToolTips(TRUE) in OnInitialUpdate
2. Provide a string resource for each control that needs a tooltip with the same ID as the control using the form "Status bar text\nTool tip text"
3. Handle the TTN_NEEDTEXT notification handler in the form view derived class.

No problem. They even give source code for this. I actually did this with and had it working, but noticed it hasn't since I moved to VC++ 5.0 The handler for the TTN_NEEDTEXT messages isn't even getting called and the messages aren't being generated.

Is there something I am missing? I noticed the TTN_NEEDTEXT has been superceeded by TTN_GETDISPINFO, but they are defined as the same thing anyway. Is there an easy way to do this without actually manually doing it through the CToolTipCtrl class? How can I implement tool tips in my CFormView derived classes?
0
Comment
Question by:JagerM
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 15

Accepted Solution

by:
Tommy Hui earned 400 total points
ID: 1316720
Did you get the latest service pack for Visual C++? It fixes a tooltip problem related to the size of a structure.

If you don't have the latest service pack, look on http://www.microsoft.com/ to get it.
0
 
LVL 4

Expert Comment

by:jtwine100697
ID: 1316721
  The way I did it was to add a CToolTipCtrl member to the View, and then use CToolTipCtrl::AddTool(...) to add controls to it, and finally use CToolTipCtrl::Activate(...) to turn tooltips on and off.

   That is a lot easier than writing your own TTN_NEEDTEXT handler.

-=- James.
0
 

Author Comment

by:JagerM
ID: 1316722
Service Pack did it. Easiest 100 pts you ever got. Thanks.

I actually tried to do it with CToolTipCtrl but the bug with the stucture size must manifest with this method as well.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
Ready to get certified? Check out some courses that help you prepare for third-party exams.
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 course is ideal for IT System Administrators working with VMware vSphere and its associated products in their company infrastructure. This course teaches you how to install and maintain this virtualization technology to store data, prevent vuln…
Suggested Courses

650 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