Tooltips in a FormView RRS feed

  • Question



    I have a VC2005 (MFC) SDI application where I switch between formviews. I am having trouble getting tool tips to work inside the formview.

    In my formview class I added this code to try and get tool tips to work.

    In msg map:    ON_NOTIFY_EX(TTN_NEEDTEXT, 0, OnToolTipNotify)

    BOOL CMyFormView::OnToolTipNotify(UINT id, NMHDR* pNMHDR, LRESULT* pResult)

    //.....................code in here etc etc etc


    In Oninitialupdate I call, EnableToolTips(TRUE);

    I have editted the string resources also.

    MY PROBLEM is, there are 4 buttons want to display tooltips for, and yet a tooltip only appears for 1 of the 4 buttons. When I put a break point in the OnToolTipNotify function the function is only entered when I hover above one of the four buttons, when shorely it should be entered when I hover above any of the 4 buttons. I spent about a day trying to get it to work but I couldn't. 

    As a different approach I also tried to get tool tips to work by using the simple class - CToolTipCtrl, but I didnt have any luck with that at all.

    Can anyone offer me any help as to why tooltips are not working in my cformview?


    Friday, November 17, 2006 2:16 PM


All replies


    I'll make my question simplier. Has anyone ever got tooltips to work properly in a formview (without doing anything nasty like embedding a toolbar in the formview) ?

    I reacon theres a bug in MFC stopping it working properly.

    Can anyone suggest any web sites with examples (I've spent hours searching with google and had no luck).

    Monday, November 20, 2006 10:26 PM
  • Hello


    Re: Tooltips in a FormView


    You have probably gotten no responses to your question as the scope is a little off topic for this Forum. The more appropriate place for your question is probably the MFC newsgroup: http://msdn.microsoft.com/newsgroups/default.aspx?dg=microsoft.public.vc.mfc&lang=en&cr=US






    Friday, January 12, 2007 12:16 AM