Solved

ToolTips in a CWND?

Posted on 1997-11-18
4
512 Views
Last Modified: 2013-11-20
I'm currently sending a SendMessage command
to the tooltip object I get from _AFX_THREAD_STATE
with a ti structure that points to a child window.
The SendMessage returns TRUE for TTM_ADDTOOL, but
I never get a TTN_NEEDTEXT message for anything
but the main window.
I am setting the lpszText field to LPSTR_TEXTCALLBACK;

(The main example I'm going off of is on page 623
of Charles Petzold's "Programming Windows 95."

Help,
 Mike Eegz
 eganm@segasoft.com
0
Comment
Question by:apollyon111897
  • 2
  • 2
4 Comments
 
LVL 7

Accepted Solution

by:
galkin earned 100 total points
ID: 1310226
TTN_NEEDTEXT is ent to the tooltip owner window. If you work with a toolbar this message(actually TTN_NEEDTEXTA for ANSI and TTN_NEEDTEXTW for UNICODE) is sent to toolbar parent window
0
 

Author Comment

by:apollyon111897
ID: 1310227
2 clarifications:

What's an ent?

I'm not using a toolbar.  That would make the problem trivial.
My problem is that I've got a CWND with a bunch of buttons, lists, etc. in it.  I want to upgrade it by adding tooltips.

Thanks
0
 
LVL 7

Expert Comment

by:galkin
ID: 1310228
Implement message handler for TTN_NEEDTEXTA and TTN_NEEDTEXTW. You can copy code from CFrameWnd class. Add corresponding string to string table.
0
 

Author Comment

by:apollyon111897
ID: 1310229
I'm not getting any NEEDTEXT messages when I leave my mouse
over any of the window's children.
Only the Window is giving a NEEDTEXT callback.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Need Help INsttalling wget on Mavericks OS X 3 83
sumNumber challenge 16 99
countEvens challenge 2 59
centeredAverage challenge 8 124
In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
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.
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

760 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

20 Experts available now in Live!

Get 1:1 Help Now