Solved

ToolTips on  Popup Menus

Posted on 1998-01-08
2
582 Views
Last Modified: 2013-11-20
I need to display a ToolTip on a CMenu popup menu.  I can get the tip text but the CToolTipCtrl needs a parent window and the CMenu is not derived form a CWnd. I tried the MainFrame window but this forces the popup menu to disappear right after it comes up.  Any other suggestions?
0
Comment
Question by:traott
2 Comments
 
LVL 7

Accepted Solution

by:
galkin earned 100 total points
ID: 1313638
When you selct menu item in popup menu WM_MENUSELECT message is sent to menu owner window. You can use GetCursorPos Win32 API function to get current cursor position and then WindowFromPoint to get menu temporary window handle beneith the mouse pointer. Now you can create tooltip control passing this temporary window handle as owner window, add tool and acticvate it.
0
 

Expert Comment

by:allanephillips
ID: 39035499
I would like to see what the code looks like in this OnMenuSelect() method.
0

Featured Post

ScreenConnect 6.0 Free Trial

Want empowering updates? You're in the right place! Discover new features in ScreenConnect 6.0, based on partner feedback, to keep you business operating smoothly and optimally (the way it should be). Explore all of the extras and enhancements for yourself!

Question has a verified solution.

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

Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
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 Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.

809 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