<?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 : AddSwapoutCommand</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Command Bars : AddSwapoutCommand]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Thu, 14 May 2026 01:06:46 +0000</pubDate>
  <lastBuildDate>Sun, 27 Nov 2011 12:49:33 +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=19230</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[AddSwapoutCommand : 	// Input:	nSwapOutID - The command...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=19230&amp;PID=66928&amp;title=addswapoutcommand#66928</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1550">dehilster</a><br /><strong>Subject:</strong> 19230<br /><strong>Posted:</strong> 27 November 2011 at 12:49pm<br /><br /><div><span ="Apple-tab-span" style="white-space:pre">	</span>// Input:<span ="Apple-tab-span" style="white-space:pre">	</span>nSwapOutID - The command ID of the menu item, defined in the menu resource,</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>that should be replaced.<span ="Apple-tab-span" style="white-space:pre">		</span></div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>nCommandID - The command ID to add to the menu.</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>szName - The menu string to add.</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>// Summary: Call this method to set one or more swapout IDs, in the case where</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>there is a dynamic menu item. An example of where this can be used is</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>the MRU in a standard doc/view application. Add a single command</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>to the menu resource that can be swapped out with the commands you</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>set here. Call this method once for each command you want to replace.</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>For example, if you had a command ID called IDC_MRUPLACEHOLDER, and</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>you wanted to add four new items in place of this which are IDC_MRUFILE1,</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>IDC_MRUFILE2, IDC_MRUFILE3, IDC_MRUFILE4 you should do the following: -</div><div>&nbsp; &nbsp; // &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&lt;pre&gt;</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>//<span ="Apple-tab-span" style="white-space:pre">			</span>kbsm.AddSwapoutCommand(IDC_MRUPLACEHOLDER, IDC_MRUFILE1, "File 1");</div><div>&nbsp; &nbsp; // &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kbsm.AddSwapoutCommand(IDC_MRUPLACEHOLDER, IDC_MRUFILE2, "File 2");</div><div>&nbsp; &nbsp; // &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kbsm.AddSwapoutCommand(IDC_MRUPLACEHOLDER, IDC_MRUFILE3, "File 3");</div><div>&nbsp; &nbsp; // &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kbsm.AddSwapoutCommand(IDC_MRUPLACEHOLDER, IDC_MRUFILE4, "File 4");&lt;/pre&gt;</div><div><span ="Apple-tab-span" style="white-space:pre">	</span>void AddSwapoutCommand(UINT nSwapOutID, UINT nCommandID, LPCTSTR szName);</div><div><br></div><div>I read the above but cannot see how to use it.</div><div><br></div>]]>
   </description>
   <pubDate>Sun, 27 Nov 2011 12:49:33 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=19230&amp;PID=66928&amp;title=addswapoutcommand#66928</guid>
  </item> 
 </channel>
</rss>