<?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 : Toolbar and images</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Command Bars : Toolbar and images]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Thu, 11 Jun 2026 05:44:25 +0000</pubDate>
  <lastBuildDate>Thu, 17 Apr 2008 13:36:00 +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=10255</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[Toolbar and images : Oh, that explains things :-)Thanks...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33854&amp;title=toolbar-and-images#33854</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4099">radcap</a><br /><strong>Subject:</strong> 10255<br /><strong>Posted:</strong> 17 April 2008 at 1:36pm<br /><br />Oh, that explains things :-)<br><br>Thanks for your help and immense amount of info on the forum, I think I wouldn't find the solution so quick without it.<br><br>]]>
   </description>
   <pubDate>Thu, 17 Apr 2008 13:36:00 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33854&amp;title=toolbar-and-images#33854</guid>
  </item> 
  <item>
   <title><![CDATA[Toolbar and images : This conversion: CXTPImageManagerIconHandle...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33850&amp;title=toolbar-and-images#33850</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 10255<br /><strong>Posted:</strong> 17 April 2008 at 1:22pm<br /><br />This conversion:<DIV>CXTPImageManagerIconHandle xtpIconHandle(hBitmap);</DIV><DIV>only works for alpha bitmaps.</DIV><DIV>&nbsp;</DIV><DIV>use SetIcons method instead.</DIV>]]>
   </description>
   <pubDate>Thu, 17 Apr 2008 13:22:55 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33850&amp;title=toolbar-and-images#33850</guid>
  </item> 
  <item>
   <title><![CDATA[Toolbar and images : Hi again.Hmm, I think now I need...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33847&amp;title=toolbar-and-images#33847</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4099">radcap</a><br /><strong>Subject:</strong> 10255<br /><strong>Posted:</strong> 17 April 2008 at 1:16pm<br /><br />Hi again.<br><br>Hmm, I think now I need some explanation:<br>in the code I posted earlier I used SetIcon method. The bitmap itself, though is a toolbar resource, is an image of a single button (so I wanted to set it twice for both buttons).<br>I changed the code to this:<br><br><table width="99%"><tr><td><pre class="BBcode"><br>//...<br>// Was:<br>//<br>// HBITMAP hBitmap = ::LoadBitmap(GetModuleHandle(0), <br>//&nbsp;&nbsp; &nbsp; MAKEINTRESOURCE(IDR_BITMAP_XXX));<br>// pCAppModeToolbar-&gt;GetImageManager()-&gt;SetIcon(<br>//&nbsp;&nbsp;  CXTPImageManagerIconHandle(hBitmap), 1);<br>//<br>// Now:<br><br>static UINT commonBtns = { 1 };<br><br>pCAppModeToolbar-&gt;GetImageManager()-&gt;SetIcons(<br>&nbsp;&nbsp;&nbsp; IDR_BITMAP_XXX, <br>&nbsp;&nbsp;&nbsp; commonBtns, <br>&nbsp;&nbsp;&nbsp; _countof(commonBtns), <br>&nbsp;&nbsp;&nbsp; CSize(16,16));<br></pre></td></tr></table><br><br>and all went good, I've got my image displayed on the button. After that, I've found out that to set image for the second button (which in fact is in the different command bar, thus I'm showing only one button in the code here) I need to use another ImageManager, but that means little now, because the idea itself works.<br><br>So, why doesn't the SetIcon work as I expected it would? LoadBitmap definetly returned the needed bitmap, I've checked that out. Is this an issue with XTP 9.60, or I still did something wrong?<br>]]>
   </description>
   <pubDate>Thu, 17 Apr 2008 13:16:24 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33847&amp;title=toolbar-and-images#33847</guid>
  </item> 
  <item>
   <title><![CDATA[Toolbar and images : Here&amp;#039;s the code from main...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33840&amp;title=toolbar-and-images#33840</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4099">radcap</a><br /><strong>Subject:</strong> 10255<br /><strong>Posted:</strong> 17 April 2008 at 10:46am<br /><br />Here's the code from main application (not a plugin), the problem resides with it as well:<br><br><table width="99%"><tr><td><pre class="BBcode"><br>HBITMAP hBitmap = ::LoadBitmap(GetModuleHandle(0), MAKEINTRESOURCE(IDR_BITMAP_XXX));<br><br>if (hBitmap)<br>{<br>&nbsp;&nbsp;&nbsp; CXTPImageManagerIconHandle xtpIconHandle(hBitmap);<br>&nbsp;&nbsp;&nbsp; pCAppModeToolbar-&gt;GetImageManager()-&gt;SetIcon(xtpIconHandle,1);<br>&nbsp;&nbsp;&nbsp; pCAppModeToolbar-&gt;GetImageManager()-&gt;SetIcon(xtpIconHandle,2);<br>}<br><br>CXTPControl* pControl = pCAppModeToolbar-&gt;GetControls()-&gt;Add(xtpControlSplitButtonPopup,1);<br><br>pControl-&gt;SetCaption(_T("Action 1"));<br>pControl-&gt;SetStyle(xtpButtonIconAndCaption);<br>// pControl-&gt;SetIconId(1); // doesn't help<br><br>// Add second button to drop-down toolbar<br>pControl = pControl-&gt;GetCommandBar()-&gt;GetControls()-&gt;Add(xtpControlButton,2);<br>pControl-&gt;SetCaption(_T("Action 2"));<br>// pControl-&gt;SetIconId(2); // doesn't help<br></pre></td></tr></table><br>]]>
   </description>
   <pubDate>Thu, 17 Apr 2008 10:46:51 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33840&amp;title=toolbar-and-images#33840</guid>
  </item> 
  <item>
   <title><![CDATA[Toolbar and images : :-)Yeah, that wasn&amp;#039;t really...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33834&amp;title=toolbar-and-images#33834</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4099">radcap</a><br /><strong>Subject:</strong> 10255<br /><strong>Posted:</strong> 17 April 2008 at 10:00am<br /><br />:-)<br><br>Yeah, that wasn't really obvious from my post, but I do use toolbar's ImageManager :-)<br>]]>
   </description>
   <pubDate>Thu, 17 Apr 2008 10:00:42 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33834&amp;title=toolbar-and-images#33834</guid>
  </item> 
  <item>
   <title><![CDATA[Toolbar and images : Hi, try instead of global XTPImageManger...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33829&amp;title=toolbar-and-images#33829</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 10255<br /><strong>Posted:</strong> 17 April 2008 at 8:45am<br /><br />Hi,<DIV>try instead of global XTPImageManger call</DIV><DIV>&nbsp;</DIV><DIV>m_wndToolBar.GetImageManager()-&gt;SetIcons(...);</DIV><DIV>&nbsp;</DIV><DIV>just set icon with Id of button and you don't need to call SetIconId for this case.</DIV>]]>
   </description>
   <pubDate>Thu, 17 Apr 2008 08:45:46 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33829&amp;title=toolbar-and-images#33829</guid>
  </item> 
  <item>
   <title><![CDATA[Toolbar and images : If I wasn&amp;#039;t too clear: In...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33821&amp;title=toolbar-and-images#33821</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4099">radcap</a><br /><strong>Subject:</strong> 10255<br /><strong>Posted:</strong> 17 April 2008 at 7:23am<br /><br /><P>If I wasn't too clear:</P><DIV>In the discussion there are advices to use -&gt;ImageManager()-&gt;SetIcon(s) method to add images to the manager, and then all one needs is just to use CXTPControl::SetIconId() method.</DIV><DIV>&nbsp;</DIV><DIV>I try to achieve this at runtime as this:</DIV><DIV>Plugin gets loaded and fetches a pointer to the toolbar. It may add controls to the toolbar, but I've been unable to attach icons to the controls.</DIV><DIV>&nbsp;</DIV><DIV>If I understand all clear, the plugin needs first to SetIcon() to attach its icon to imagemanager and then just to call SetIconId() for the added control. But icon doesn't show up. What am I doing wrong?</DIV>]]>
   </description>
   <pubDate>Thu, 17 Apr 2008 07:23:43 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33821&amp;title=toolbar-and-images#33821</guid>
  </item> 
  <item>
   <title><![CDATA[Toolbar and images : Hello,searching through topics...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33756&amp;title=toolbar-and-images#33756</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4099">radcap</a><br /><strong>Subject:</strong> 10255<br /><strong>Posted:</strong> 16 April 2008 at 10:40am<br /><br />Hello,<br>searching through topics I could not fully realize if I can make a true dynamic setup for toolbars:<br><br>I need a popup toolbar with xtpButtonIconAndCaption button styles, and it has to allow dynamic addition of buttons (say, for plugins). How can I set it up so I get icons displayed? Right now I can only see the captions, but no icons. <br><br>Can you tell me whether I can achieve such behavior and if I can, then how?<br><br>I use XTP v9.60 (and there are reasons that restrict me to this version :-( )<br>]]>
   </description>
   <pubDate>Wed, 16 Apr 2008 10:40:12 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=10255&amp;PID=33756&amp;title=toolbar-and-images#33756</guid>
  </item> 
 </channel>
</rss>