<?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 : Deleting Incorrect Row</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Report Control : Deleting Incorrect Row]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Tue, 28 Apr 2026 19:16:52 +0000</pubDate>
  <lastBuildDate>Sun, 09 May 2010 05:31:01 +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=16664</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[Deleting Incorrect Row : Hi,  Is your issue related to...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=16664&amp;PID=58381&amp;title=deleting-incorrect-row#58381</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3701">Aaron</a><br /><strong>Subject:</strong> 16664<br /><strong>Posted:</strong> 09 May 2010 at 5:31am<br /><br />Hi,<DIV>&nbsp;</DIV><DIV>Is your issue related to <a href="https://forum.codejock.com/forum_posts.asp?TID=11560" target="_blank">https://forum.codejock.com/forum_posts.asp?TID=11560</A>&nbsp;Are you removing records&nbsp;within the SelectedRows collection? If I remove a record with .RemoveRecordEx(row.record) &nbsp;or&nbsp; .RemoveAt(row.record.index) method shouldn't make a difference. Can you show code you used when it didn't work? </DIV><DIV>&nbsp;</DIV><DIV>Thanks</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Sun, 09 May 2010 05:31:01 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=16664&amp;PID=58381&amp;title=deleting-incorrect-row#58381</guid>
  </item> 
  <item>
   <title><![CDATA[Deleting Incorrect Row : using the rptMainMessages.Remo...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=16664&amp;PID=58350&amp;title=deleting-incorrect-row#58350</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=5754">XiMaker</a><br /><strong>Subject:</strong> 16664<br /><strong>Posted:</strong> 06 May 2010 at 2:11pm<br /><br />using the rptMainMessages.RemoveRecordEx(row.Record.Index); seems to have done the trick - I was consistently having the problem before using the RemoveAt and have not been able to reproduce the problem at all when using RemoveRecordEx - thanks...]]>
   </description>
   <pubDate>Thu, 06 May 2010 14:11:48 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=16664&amp;PID=58350&amp;title=deleting-incorrect-row#58350</guid>
  </item> 
  <item>
   <title><![CDATA[Deleting Incorrect Row : Possibly you want rptMainMessa...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=16664&amp;PID=58349&amp;title=deleting-incorrect-row#58349</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=369">SuperMario</a><br /><strong>Subject:</strong> 16664<br /><strong>Posted:</strong> 06 May 2010 at 1:42pm<br /><br /><br>Possibly you want <br><br>rptMainMessages.Records.RemoveAt(<span ="highlight">row</span>.Record.Index);<br>rptMainMessages.Populate();<br><br>OR<br><br>rptMainMessages.RemoveRecordEx(<span ="highlight">row</span>.Record.Index);<br>rptMainMessages.<span ="highlight">Row</span>Ex(<span ="highlight">row</span>);<br><br>OR<br><br>Sub <span ="highlight">Delete</span>()<br>Dim i As Long, <span ="highlight">Row</span> As Report<span ="highlight">Row</span><br>&nbsp;If lst.Selected<span ="highlight">Row</span>s.Count = 0 Then<br>&nbsp;&nbsp;&nbsp; If lst.Records.Count = 0 Then<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Debug.Print "No <span ="highlight">Row</span>(s) Exist to Remove"<br>&nbsp;&nbsp;&nbsp; Else<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Debug.Print "Select The <span ="highlight">Row</span>(s) you want to remove"<br>&nbsp;&nbsp;&nbsp; End If<br>&nbsp;ElseIf lst.Selected<span ="highlight">Row</span>s.Count &gt;= 1 Then<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Debug.Print "Ready TO Remove : " &amp; lst.Selected<span ="highlight">Row</span>s.Count &amp; " <span ="highlight">Row</span>(s)"<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; If MsgBox("Are You Sure", vbInformation + vbYesNo) = vbNo Then<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; lblStatus.Caption = "Remove cancelled"<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Exit Sub<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; End If<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; For Each <span ="highlight">Row</span> In lst.Selected<span ="highlight">Row</span>s<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span ="highlight">Delete</span> <span ="highlight">Row</span><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; lst.Records.RemoveAt (<span ="highlight">Row</span>.Record.Index)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Next<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Debug.Print "Selected <span ="highlight">Row</span>s removed successfully"<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; lst.Populate<br>&nbsp;End If<br>End Sub<br><br>]]>
   </description>
   <pubDate>Thu, 06 May 2010 13:42:19 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=16664&amp;PID=58349&amp;title=deleting-incorrect-row#58349</guid>
  </item> 
  <item>
   <title><![CDATA[Deleting Incorrect Row : I have an odd issue where I am...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=16664&amp;PID=58348&amp;title=deleting-incorrect-row#58348</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=5754">XiMaker</a><br /><strong>Subject:</strong> 16664<br /><strong>Posted:</strong> 06 May 2010 at 1:09pm<br /><br />I have an odd issue where I am deleting records from the reportcontrol and everything works like it should most of the time but at some point even when nothing else has changed, it will start deleting rows 2 or 3 lines below where the focusedrow is located.&nbsp;&nbsp;&nbsp;during the debug phase I can see that the selectedrow.record contains the correct information that should be deleted but when I issue the removeat and then populate the row 2 or 3 lines below will go away.  if I try to delete the same row again it throws an error like the correct row does not exist but it is showing on the reportcontrol row.&nbsp;&nbsp;&nbsp;ANY IDEAS?]]>
   </description>
   <pubDate>Thu, 06 May 2010 13:09:03 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=16664&amp;PID=58348&amp;title=deleting-incorrect-row#58348</guid>
  </item> 
 </channel>
</rss>