<?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 : Default C&#111;ntext Menu &#111;n Edit C&#111;ntrol</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Toolkit Pro : Default C&#111;ntext Menu &#111;n Edit C&#111;ntrol]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Tue, 21 Apr 2026 21:43:29 +0000</pubDate>
  <lastBuildDate>Wed, 17 Aug 2005 17:50:18 +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=2738</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[Default C&#111;ntext Menu &#111;n Edit C&#111;ntrol :   My last post is absurd. I...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=2738&amp;PID=8195&amp;title=default-context-menu-on-edit-control#8195</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1233">mwest</a><br /><strong>Subject:</strong> 2738<br /><strong>Posted:</strong> 17 August 2005 at 5:50pm<br /><br />My last post is absurd.&nbsp; I have been looking at code for too long. &nbsp;<img src="http://forum.codejock.com/smileys/smiley11.gif" border="0"><br><br><em><em>CXTPControlEditCtrl</em></em> <strong>is</strong> derived from <em>CEdit</em>.&nbsp; Sorry about that.<br><br><br>I did come up with a way to get the context menu instead of the menu pop up:<br><br>1.&nbsp; Make a custom derived <em>CXTPControlEdit</em> and the EditControl class that CreateEditControl() will return (this class isderived from <em><em></em><em>CXTPControlEditCtrl</em>).&nbsp; </em>See the User Guide:&nbsp; Chapter 4 - How to Add Custom Command Bar Controls to Your Application.<br><br>2.&nbsp; The edit control class (the one derived from <em><em></em><em>CXTPControlEditCtrl</em></em>) should override the OnRButtonDown() handler (ON_WM_RBUTTONDOWN()).<br><br>3.&nbsp; Then just call the <em>CXTPEdit::OnRButtonDown()</em> instead of the <em><em></em><em>CXTPControlEditCtrl</em>::OnRButtonDown</em> (<em><em>CXTPControlEditCtrl</em></em>'s method creates the menu that has Cut, Paste, etc...&nbsp; Take a look at the source for it.)<br><br>4.&nbsp; Override the OnContextMenu() handler (ON_WM_CONTEXTMENU()) inaccordance with however you want your context menu to look.&nbsp; See<a href="http://www.codeproject.com/editctrl/cmenuedit.asp" target="_blank">http://www.codeproject.com/editctrl/cmenuedit.asp</a><br><br>5.&nbsp; Run it and you will see your context menu.<br><br><span style="color: rgb(204, 204, 204);">Here are a few keywords for people searching for this solution:<br>copy, paste, cut, toolbar, context menu, edit, right click,ShowContextMenu, CXTPEdit, ID_EDIT_CUT, ID_EDIT_COPY, ID_EDIT_PASTE,default context menu<br></span> <span style="font-size:10px"><br /><br />Edited by mwest</span>]]>
   </description>
   <pubDate>Wed, 17 Aug 2005 17:50:18 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=2738&amp;PID=8195&amp;title=default-context-menu-on-edit-control#8195</guid>
  </item> 
  <item>
   <title><![CDATA[Default C&#111;ntext Menu &#111;n Edit C&#111;ntrol : I have a CXTPControlEditCtrl in...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=2738&amp;PID=8188&amp;title=default-context-menu-on-edit-control#8188</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1233">mwest</a><br /><strong>Subject:</strong> 2738<br /><strong>Posted:</strong> 17 August 2005 at 12:21pm<br /><br />I have a <em>CXTPControlEditCtrl</em> in a toolbar that displays adefault context menu when I right click on it.&nbsp; I would like toprovide a custom context menu, but I am unsure how to do it.&nbsp; If<em>CXTPControlEditCtrl</em> was derived from <em>CEdit</em> instead of<em>CXTPControl</em> I would know what do do.&nbsp; Can anyone help me?<br><br>Here is an article on how to do it normally:<br><a href="http://www.codeproject.com/editctrl/cmenuedit.asp" target="_blank">http://www.codeproject.com/editctrl/cmenuedit.asp</a><br><br>Thanks!]]>
   </description>
   <pubDate>Wed, 17 Aug 2005 12:21:37 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=2738&amp;PID=8188&amp;title=default-context-menu-on-edit-control#8188</guid>
  </item> 
 </channel>
</rss>