<?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 : ReportControl auto-numbering</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Report Control : ReportControl auto-numbering]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Sat, 18 Apr 2026 13:17:06 +0000</pubDate>
  <lastBuildDate>Wed, 04 Nov 2009 17:12:13 +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=15535</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[ReportControl auto-numbering : This is totallysystem-filled column...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15535&amp;PID=54568&amp;title=reportcontrol-autonumbering#54568</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 15535<br /><strong>Posted:</strong> 04 November 2009 at 5:12pm<br /><br />This is totally&nbsp;system-filled column - it show current row (or rec) index. I attach my code to show you the order of initialization steps. No need any other code to use number column but&nbsp;you can&nbsp;switch <FONT size=2>GetReportCtrl().GetPaintManager()-&gt;m_bRecOrRowNum = TRUE or FALSE</FONT>]]>
   </description>
   <pubDate>Wed, 04 Nov 2009 17:12:13 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15535&amp;PID=54568&amp;title=reportcontrol-autonumbering#54568</guid>
  </item> 
  <item>
   <title><![CDATA[ReportControl auto-numbering : Thanks Mark, but I&amp;#039;ve already...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15535&amp;PID=54567&amp;title=reportcontrol-autonumbering#54567</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4876">unknow</a><br /><strong>Subject:</strong> 15535<br /><strong>Posted:</strong> 04 November 2009 at 4:59pm<br /><br />Thanks Mark, but I've already taken some portions of the code you posted; <DIV>&nbsp;</DIV><DIV>My ReportControl is already implemented &amp; working and I just want to add the 1st column with numbers.</DIV><DIV>&nbsp;</DIV><DIV>As I wrote, the "rec#" column is present but I don't understand how to fill the value, instead of having numbers, I get a copy of the first column which contains text !!????</DIV><DIV>&nbsp;</DIV><DIV>In this code you posted, which lines make the thing work ?</DIV><DIV>&nbsp;</DIV><DIV>Thankx!</DIV>]]>
   </description>
   <pubDate>Wed, 04 Nov 2009 16:59:37 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15535&amp;PID=54567&amp;title=reportcontrol-autonumbering#54567</guid>
  </item> 
  <item>
   <title><![CDATA[ReportControl auto-numbering :  void CReportPaneViewView::OnInitialUpdate()...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15535&amp;PID=54502&amp;title=reportcontrol-autonumbering#54502</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 15535<br /><strong>Posted:</strong> 02 November 2009 at 5:58pm<br /><br /><FONT color=#0000ff size=2><P>void</FONT><FONT size=2> CReportPaneViewView::OnInitialUpdate()&nbsp; {</P><P>CXTPReportView::OnInitialUpdate();</P><P>CString columnStr;</P><P></FONT><FONT color=#0000ff size=2>for</FONT><FONT size=2> (</FONT><FONT color=#0000ff size=2>int</FONT><FONT size=2> i = 0; i &lt; COL_NUMBER; i++) { columnStr.Format(</FONT><FONT color=#a31515 size=2>"Column %d"</FONT><FONT size=2>,i);</P><P>CXTPReportColumn* pCol = GetReportCtrl().AddColumn(</FONT><FONT color=#0000ff size=2>new</FONT><FONT size=2> CXTPReportColumn(i, columnStr, 60, FALSE,XTP_REPORT_NOICON,TRUE));</P><P>pCol-&gt;EnableResize(TRUE); }</P><P></FONT><FONT color=#0000ff size=2>for</FONT><FONT size=2> (</FONT><FONT color=#0000ff size=2>int</FONT><FONT size=2> j = 0; j &lt; ROW_NUMBER; j++)&nbsp; GetReportCtrl().AddRecord(</FONT><FONT color=#0000ff size=2>new</FONT><FONT size=2> CReportViewRecord(j));</P><P>GetReportCtrl().Populate();</P><P>GetReportCtrl().GetReportHeader()-&gt;SetAutoColumnSizing(FALSE);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetColumnStyle(xtpReportColumnOffice2007);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetDrawGridForEmptySpace(TRUE);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetGridStyle(0, xtpReportGridSolid);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetGridStyle(1, xtpReportGridSolid);</P><P></P><P>GetReportCtrl().GetPaintManager()-&gt;SetHeaderRowsDividerStyle(xtpReportFixedRowsDividerBold);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetFooterRowsDividerStyle(xtpReportFixedRowsDividerBold);</P><P>GetReportCtrl().GetPaintManager()-&gt;m_clrHeaderRowsDivider = RGB(255,0,0);</P><P>GetReportCtrl().GetPaintManager()-&gt;m_clrFooterRowsDivider = RGB(0,0,255);</P><P>GetReportCtrl().AssignIconViewPropNumAndIconNum(-1, -1, TRUE, 20);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetLastColumnWidthWYSIWYG(TRUE);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetColumnWidthWYSIWYG(TRUE);</P><P>m_pPrintOptions-&gt;GetPageHeader()-&gt;m_strFormatString = </FONT><FONT color=#a31515 size=2>"Header text: &amp;p from &amp;P"</FONT><FONT size=2>;</P><P>m_pPrintOptions-&gt;GetPageFooter()-&gt;m_strFormatString = </FONT><FONT color=#a31515 size=2>"Footer text: &amp;D"</FONT><FONT size=2>;</P><P>GetReportCtrl().m_bForcePagination = TRUE;</P><P>GetReportCtrl().AllowEdit(TRUE);</P></FONT><FONT size=2><P>GetReportCtrl().EnableDragDrop(_T(</FONT><FONT color=#a31515 size=2>"ReportPaneView"</FONT><FONT size=2>), xtpReportAllowDragMove | xtpReportAllowDragCopy | xtpReportAllowDrop);</P></FONT><FONT size=2><P>GetReportCtrl().GetPaintManager()-&gt;SetHeaderRowsDividerStyle(xtpReportFixedRowsDividerBold);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetFooterRowsDividerStyle(xtpReportFixedRowsDividerBold);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetDrawGridForEmptySpace(TRUE);</P><P>GetReportCtrl().GetPaintManager()-&gt;SetFreezeColsDividerStyle(xtpReportFreezeColsDividerThin | xtpReportFreezeColsDividerShowAlways);</P><P>GetReportCtrl().GetColumns()-&gt;GetFirstVisibleColumn()-&gt;SetAutoSize(FALSE);</P></FONT><FONT size=2><P>GetReportCtrl().m_bDesktopTrackerMode = FALSE;</P><P>GetReportCtrl().RedrawControl();</P></FONT><FONT size=2><P>}</P></FONT>]]>
   </description>
   <pubDate>Mon, 02 Nov 2009 17:58:20 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15535&amp;PID=54502&amp;title=reportcontrol-autonumbering#54502</guid>
  </item> 
  <item>
   <title><![CDATA[ReportControl auto-numbering : Hi. I would like to include an...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15535&amp;PID=54501&amp;title=reportcontrol-autonumbering#54501</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4876">unknow</a><br /><strong>Subject:</strong> 15535<br /><strong>Posted:</strong> 02 November 2009 at 5:09pm<br /><br /><P>Hi. I would like to include an automatic line numbering column as seen in the ReportPaneView sample; </P><DIV></DIV>I understand it uses the "AssignIconViewPropNumAndIconNum" method but I can't get it working, the "rec#" column includes a copy of the 1st column which is text;<DIV>&nbsp;</DIV><DIV>An additional question: how to force the current focused row to switch to edit mode for the 1st column (bAllowEdit is set and works with mouse).</DIV><DIV>&nbsp;</DIV><DIV>Thankx !!</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Mon, 02 Nov 2009 17:09:22 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15535&amp;PID=54501&amp;title=reportcontrol-autonumbering#54501</guid>
  </item> 
 </channel>
</rss>