<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : Set tooltip text and description dynamically</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Toolkit Pro : Set tooltip text and description dynamically]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Tue, 21 Apr 2026 10:03:15 +0000</pubDate>
  <lastBuildDate>Wed, 16 Dec 2009 07:00:48 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=15858</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[Set tooltip text and description dynamically : Thanks Oleg. I tried this and...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15858&amp;PID=55682&amp;title=set-tooltip-text-and-description-dynamically#55682</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3101">iftekhar</a><br /><strong>Subject:</strong> 15858<br /><strong>Posted:</strong> 16 December 2009 at 7:00am<br /><br /><P style="MARGIN: 0cm 0cm 0pt" =Ms&#111;normal><SPAN style="FONT-FAMILY: Verdana; COLOR: black; FONT-SIZE: 13pt; mso-ansi-: EN" lang=EN><FONT face="Arial, Helvetica, sans-serif"><FONT size=2>Thanks Oleg. I tried this and it works. But this message is send once the tooltip is displayed. Therefore the first time I select a control the old tool tip is displayed then the WM_XTP_CONTROLSELECTED is handled. Then when I select the control second time the tooltip set for the control in WM_XTP_CONTROLSELECTED handler function is displayed. I tried setting an initial tool tip ON_XTP_AFTERCREATECONTROL() but that is no help to me because the user can change the tool tip mode after the controls are created at runtime which brings me to square one again. So is there any other message like WM_XTP_CONTROLSELECTED which is handled before tool tip is displayed. <?:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p></FONT></FONT></SPAN></P><P style="MARGIN: 0cm 0cm 0pt" =Ms&#111;normal><SPAN style="FONT-FAMILY: Verdana; COLOR: black; FONT-SIZE: 13pt; mso-ansi-: EN" lang=EN><FONT face="Arial, Helvetica, sans-serif"><FONT size=2>&nbsp;<o:p></o:p></FONT></FONT></SPAN></P><P style="MARGIN: 0cm 0cm 0pt" =Ms&#111;normal><SPAN style="FONT-FAMILY: Verdana; COLOR: black; FONT-SIZE: 13pt; mso-ansi-: EN" lang=EN><FONT face="Arial, Helvetica, sans-serif"><FONT size=2>Regards<o:p></o:p></FONT></FONT></SPAN></P><P style="MARGIN: 0cm 0cm 0pt" =Ms&#111;normal><SPAN style="FONT-FAMILY: Verdana; COLOR: black; FONT-SIZE: 13pt; mso-ansi-: EN" lang=EN><FONT face="Arial, Helvetica, sans-serif"><FONT size=2>&nbsp;<o:p></o:p></FONT></FONT></SPAN></P><P style="MARGIN: 0cm 0cm 0pt" =Ms&#111;normal><SPAN style="FONT-FAMILY: Verdana; COLOR: black; FONT-SIZE: 13pt; mso-ansi-: EN" lang=EN><FONT face="Arial, Helvetica, sans-serif"><FONT size=2>Iftekhar<o:p></o:p></FONT></FONT></SPAN></P>]]>
   </description>
   <pubDate>Wed, 16 Dec 2009 07:00:48 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15858&amp;PID=55682&amp;title=set-tooltip-text-and-description-dynamically#55682</guid>
  </item> 
  <item>
   <title><![CDATA[Set tooltip text and description dynamically : Hi,   You can catch WM_XTP_CONTROLSELECTED...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15858&amp;PID=55673&amp;title=set-tooltip-text-and-description-dynamically#55673</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 15858<br /><strong>Posted:</strong> 16 December 2009 at 5:32am<br /><br />Hi, <DIV>&nbsp;</DIV><DIV>You can catch WM_XTP_CONTROLSELECTED message. if wParam is not NULL it will point to new selected control.</DIV>]]>
   </description>
   <pubDate>Wed, 16 Dec 2009 05:32:57 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15858&amp;PID=55673&amp;title=set-tooltip-text-and-description-dynamically#55673</guid>
  </item> 
  <item>
   <title><![CDATA[Set tooltip text and description dynamically : Hi,   I am working with CXTPCommandBars,...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15858&amp;PID=55649&amp;title=set-tooltip-text-and-description-dynamically#55649</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3101">iftekhar</a><br /><strong>Subject:</strong> 15858<br /><strong>Posted:</strong> 15 December 2009 at 7:26am<br /><br />Hi, <DIV>&nbsp;</DIV><DIV>I am working with CXTPCommandBars, which I use to create menubar and toolbar from frame and dialog window. I would like to set tooltip text and description dynamically when the mouse hovers on the toolbar controls.</DIV><DIV>&nbsp;</DIV><DIV>I am using xtpToolTipLuna stype for the tool tip.<EM> </EM>I did the following to change the style of the tooltip.</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;</DIV><DIV><FONT face="Courier New, Courier, mono">void CSwToolTipCtrl::UpdateToolTipStyle(CXTPCommandBars* pCommandBars)<BR>{<BR>&nbsp;&nbsp;&nbsp; if (!pCommandBars)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return;</FONT></DIV><DIV><FONT face="Courier New, Courier, mono">&nbsp;&nbsp;&nbsp; pCommandBars-&gt;GetCommandBarsOptions()-&gt;bShowPopupBarToolTips = TRUE;<BR>&nbsp;&nbsp;&nbsp; if (CSwToolTipCtrl::m_nToolTipMode == TOOLTIP_MODE_NOVICE)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; pCommandBars-&gt;GetCommandBarsOptions()-&gt;ShowKeyboardCues(xtpKeyboardCuesShowWindowsDefault);<BR>&nbsp;&nbsp;&nbsp; pCommandBars-&gt;GetToolTipContext()-&gt;SetStyle(xtpToolTipLuna);<BR>&nbsp;&nbsp;&nbsp; pCommandBars-&gt;GetToolTipContext()-&gt;ShowTitleAndDescription(CSwToolTipCtrl::m_nToolTipMode == TOOLTIP_MODE_NOVICE);<BR>&nbsp;&nbsp;&nbsp; pCommandBars-&gt;GetToolTipContext()-&gt;ShowImage(TRUE);<BR>}</FONT></DIV><DIV><FONT face="Arial, Helvetica, sans-serif"></FONT>&nbsp;</DIV><DIV>&nbsp;</DIV><DIV>But the tooltip text is loaded from the resource which I don't want and provide my own text and description. The text and description is provided based on the id of the control. Therefore when the mouse&nbsp;hover on a control I have to call SetDescription("Text") for that CXTPControl. But I might need a callback function or message handler to where I can do this. I tried OnToolTipText which is not getting called for CXTPCommandBars unlike standard MFC and OnToolHitTest which I did not have much luck with.</DIV><DIV>&nbsp;</DIV><DIV>Could anybody please shed some light on it and tell me how I can do this?</DIV><DIV>&nbsp;</DIV><DIV>Thanks in advance</DIV><DIV>&nbsp;</DIV><DIV>Iftekhar<BR></DIV>]]>
   </description>
   <pubDate>Tue, 15 Dec 2009 07:26:38 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15858&amp;PID=55649&amp;title=set-tooltip-text-and-description-dynamically#55649</guid>
  </item> 
 </channel>
</rss>