<?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 : Override ReportControl copy/paste functions?</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Report Control : Override ReportControl copy/paste functions?]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Sat, 18 Apr 2026 20:28:24 +0000</pubDate>
  <lastBuildDate>Thu, 08 Oct 2009 18:57:41 +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=15295</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[Override ReportControl copy/paste functions? :   BOOL CXTPReportPaintManager::m_bForceShowDropMarker;...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53724&amp;title=override-reportcontrol-copy-paste-functions#53724</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 08 October 2009 at 6:57pm<br /><br /><DIV></DIV><DIV></DIV><FONT size=2><P>BOOL <FONT size=2>CXTPReportPaintManager::</FONT>m_bForceShowDropMarker; </FONT><FONT color=#008000 size=2>// TRUE if Force Show Drop Marker</P></FONT><FONT size=2><P></FONT><FONT color=#008000 size=2>//used to support external (OLE) drag &amp; drop handler and take care of drop marker line drawing and auto-scrolling</P></FONT>]]>
   </description>
   <pubDate>Thu, 08 Oct 2009 18:57:41 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53724&amp;title=override-reportcontrol-copy-paste-functions#53724</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? : Good ]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53717&amp;title=override-reportcontrol-copy-paste-functions#53717</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 08 October 2009 at 12:47pm<br /><br />Good]]>
   </description>
   <pubDate>Thu, 08 Oct 2009 12:47:08 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53717&amp;title=override-reportcontrol-copy-paste-functions#53717</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? : Yep, sorry, that was an easy one,...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53714&amp;title=override-reportcontrol-copy-paste-functions#53714</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4876">unknow</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 08 October 2009 at 12:38pm<br /><br />Yep, sorry, that was an easy one, here's the answer for those who would be interested:<DIV>&nbsp;</DIV><DIV><strong>Add this handle in the ReportView (dont' forget include file declaration):</strong></DIV><DIV>&nbsp;ON_NOTIFY(XTP_NM_REPORT_DROP, XTP_ID_REPORT_CONTROL, OnReportDrop)</DIV><DIV>&nbsp;</DIV><DIV><strong>Then this code:</strong></DIV><DIV><FONT color=#0000ff>void</FONT> CReportSampleView::OnReportDrop(NMHDR * pNotifyStruct, LRESULT * <FONT color=#006600>/*result*/</FONT>)<BR>{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; XTP_NM_REPORTDRAGDROP* pItemNotify = (XTP_NM_REPORTDRAGDROP*)pNotifyStruct;</DIV><DIV>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ASSERT(pItemNotify-&gt;pRecords);</DIV><DIV>&nbsp;</DIV><DIV><FONT color=#006600>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // in this example, we access to a derivated CXTPReportRecord class with a GetTitle function&nbsp;</FONT></DIV><DIV>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; CString strTitle;</DIV><DIV>&nbsp;</DIV><DIV><FONT color=#006600>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;// handle each dropped record one after another</FONT><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for (int i=0; i&lt;pItemNotify-&gt;pRecords-&gt;GetCount(); i++)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CMyDerivatedRecord* pRecord = ((CMyDerivatedRecord*)pItemNotify-&gt;pRecords-&gt;GetAt(i));</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;strTitle = (pRecord-&gt;GetAt(i))-&gt;GetTitle();</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<FONT color=#006600>// do something, like for example change Title to avoid duplicates&nbsp;;-)</FONT></DIV><DIV><FONT color=#006600><FONT color=#000000>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ChangeTitleFunction(strTitle);</FONT></FONT></DIV><DIV><FONT color=#006600><FONT color=#000000></FONT></FONT>&nbsp;</DIV><DIV><FONT color=#006600><FONT color=#000000>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;((CXTPReportRecordItemText*)pRecord-&gt;GetItem(IDX_TITLE))-&gt;SetValue(strTitle);</FONT><BR></FONT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<BR>}<BR></DIV><DIV>This example should work for any other DragnDrop notification messages;</DIV>]]>
   </description>
   <pubDate>Thu, 08 Oct 2009 12:38:40 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53714&amp;title=override-reportcontrol-copy-paste-functions#53714</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? : I am sure you can do this research...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53710&amp;title=override-reportcontrol-copy-paste-functions#53710</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 08 October 2009 at 12:09pm<br /><br />I am sure you can do this research yourself]]>
   </description>
   <pubDate>Thu, 08 Oct 2009 12:09:48 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53710&amp;title=override-reportcontrol-copy-paste-functions#53710</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? : ok, I forgot to ask: how to retrieve...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53683&amp;title=override-reportcontrol-copy-paste-functions#53683</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4876">unknow</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 07 October 2009 at 12:50pm<br /><br />ok, I forgot to ask: how to retrieve pointer to the dropped items from the handle message ?]]>
   </description>
   <pubDate>Wed, 07 Oct 2009 12:50:40 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53683&amp;title=override-reportcontrol-copy-paste-functions#53683</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? : If you wish ]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53681&amp;title=override-reportcontrol-copy-paste-functions#53681</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 07 October 2009 at 12:36pm<br /><br />If you wish]]>
   </description>
   <pubDate>Wed, 07 Oct 2009 12:36:42 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53681&amp;title=override-reportcontrol-copy-paste-functions#53681</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? :   mdoubson wrote: you can also...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53680&amp;title=override-reportcontrol-copy-paste-functions#53680</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4876">unknow</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 07 October 2009 at 12:34pm<br /><br /><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by mdoubson" alt="Originally posted by mdoubson" style="vertical-align: text-bottom;" /> <strong>mdoubson wrote:</strong><br /><br /><FONT size=2><DIV>you can also try the previous post way...<FONT size=2></DIV></FONT></FONT></td></tr></table> <DIV>You mean by handling messages from the control (like NM_BEGINDRAG) from the ReportView ?</DIV>]]>
   </description>
   <pubDate>Wed, 07 Oct 2009 12:34:36 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53680&amp;title=override-reportcontrol-copy-paste-functions#53680</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? : You canuse your own class derived...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53633&amp;title=override-reportcontrol-copy-paste-functions#53633</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 05 October 2009 at 9:04am<br /><br />You can&nbsp;use your own class derived from <FONT size=2>CXTPReportControl and overwrite functions <DIV><FONT size=2></FONT><FONT color=#0000ff size=2><FONT size=2><P></FONT><FONT color=#0000ff size=2></P><DIV><FONT color=#000000>virtual</FONT></FONT><FONT color=#000000><FONT size=2> </FONT><FONT size=2>void</FONT></FONT><FONT size=2><FONT color=#000000> OnBeginDrag(CPoint point);</FONT></DIV><DIV></FONT></FONT><FONT color=#000000><FONT size=2>virtual</FONT><FONT size=2> DROPEFFECT OnDragOver(COleDataObject* pDataObject, DWORD dwKeyState, CPoint point, </FONT><FONT size=2>int</FONT><FONT size=2> nState);</FONT></FONT></DIV></DIV><DIV><FONT color=#000000><FONT size=2>virtual</FONT><FONT size=2> BOOL OnDrop(COleDataObject* pDataObject, DROPEFFECT dropEffect, CPoint point);</FONT></FONT></DIV><DIV>&nbsp;</DIV><DIV>you can also try the previous post way...<FONT size=2></DIV></FONT></FONT>]]>
   </description>
   <pubDate>Mon, 05 Oct 2009 09:04:36 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53633&amp;title=override-reportcontrol-copy-paste-functions#53633</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? : Thankx! It was the easiest way...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53630&amp;title=override-reportcontrol-copy-paste-functions#53630</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4876">unknow</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 04 October 2009 at 5:50pm<br /><br />Thankx! It was the easiest way to do it <img src="https://forum.codejock.com/smileys/smiley2.gif" border="0">&nbsp;I didn't tried it as I thought the ReportControl would prevent from the CView messages;<DIV>&nbsp;</DIV><DIV>On the same way, I would also need to intercept items dragged into the ReportControl in order to change some data on the fly; </DIV><DIV>&nbsp;</DIV><DIV>Which message handled / function should I add and how to get the handles of dropped Report items ?</DIV><DIV>&nbsp;</DIV><DIV>Thankx!</DIV>]]>
   </description>
   <pubDate>Sun, 04 Oct 2009 17:50:38 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53630&amp;title=override-reportcontrol-copy-paste-functions#53630</guid>
  </item> 
  <item>
   <title><![CDATA[Override ReportControl copy/paste functions? :      ReportPaneViewView.h class...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53628&amp;title=override-reportcontrol-copy-paste-functions#53628</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 15295<br /><strong>Posted:</strong> 04 October 2009 at 3:15pm<br /><br /><DIV><FONT color=#000000></FONT></DIV><DIV><FONT color=#000000></FONT></DIV><FONT size=2><DIV><FONT size=2><DIV><FONT size=2><FONT color=#000000><DIV><FONT color=#a31515 size=2><P>ReportPaneViewView.h</P></FONT></DIV><DIV>class</FONT></FONT><FONT color=#000000><FONT size=2> CReportPaneViewView : </FONT><FONT size=2>public</FONT><FONT size=2> CXTPReportView</DIV></FONT></FONT></DIV><DIV><FONT size=2><P><FONT color=#000000>protected</FONT></FONT><FONT size=2><FONT color=#000000>:</FONT></P></FONT></FONT></DIV><DIV><FONT color=#000000>afx_msg </FONT></FONT><FONT color=#000000 size=2>void</FONT><FONT size=2><FONT color=#000000> OnEditCut();</FONT></DIV></DIV><P><FONT color=#000000>afx_msg </FONT></FONT><FONT color=#000000 size=2>void</FONT><FONT size=2><FONT color=#000000> OnEditCopy();</FONT></P><P><FONT color=#000000>afx_msg </FONT></FONT><FONT color=#000000 size=2>void</FONT><FONT size=2><FONT color=#000000> OnEditPaste();</P><DIV><FONT size=2><P>afx_msg </FONT><FONT color=#0000ff size=2>void</FONT><FONT size=2> OnUpdateEditPaste(CCmdUI* pCmdUI);</P><P>afx_msg </FONT><FONT color=#0000ff size=2>void</FONT><FONT size=2> OnUpdateEditCopy(CCmdUI* pCmdUI);</P><P>afx_msg </FONT><FONT color=#0000ff size=2>void</FONT><FONT size=2> OnUpdateEditCut(CCmdUI* pCmdUI);</P><DIV><FONT color=#a31515 size=2><P>ReportPaneViewView.cpp</P></FONT></DIV><DIV></FONT></FONT><DIV><FONT color=#000000></FONT></DIV><FONT size=2><FONT color=#000000>BEGIN_MESSAGE_MAP(CReportPaneViewView, CXTPReportView)</FONT></DIV></DIV><P></FONT><FONT size=2><FONT color=#000000>//{{AFX_MSG_MAP(CReportPaneViewView)</FONT></P></FONT><FONT size=2><P></FONT><FONT size=2><FONT color=#000000>&nbsp;ON_COMMAND(ID_EDIT_CUT, OnEditCut)</FONT></P><P><FONT size=2><FONT color=#000000>ON_COMMAND(ID_EDIT_COPY, OnEditCopy)</FONT></P></FONT><FONT size=2><P></FONT><FONT size=2><FONT color=#000000>ON_COMMAND(ID_EDIT_PASTE, OnEditPaste)</FONT></P><P></FONT><FONT color=#000000>//}}AFX_MSG_MAP</FONT></P></FONT><FONT size=2><FONT color=#000000 size=2><P>END_MESSAGE_MAP()</P></FONT></FONT><FONT color=#008000 size=2><FONT color=#0000ff size=2><P><FONT color=#000000>void</FONT></FONT><FONT color=#000000><FONT size=2> CReportPaneViewView::OnEditCut() { AfxMessageBox(_T(</FONT><FONT size=2>"OnEditCut"</FONT><FONT size=2>)); } .......</P></FONT></FONT></FONT></FONT>]]>
   </description>
   <pubDate>Sun, 04 Oct 2009 15:15:57 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15295&amp;PID=53628&amp;title=override-reportcontrol-copy-paste-functions#53628</guid>
  </item> 
 </channel>
</rss>