<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>[How Do I:] The AJAX Toolkit Reorder Control</title><link>http://www.asp.net</link><pubDate>Sat, 07 Aug 2010 13:03:53 GMT</pubDate><generator>umbraco</generator><description>Comments for [How Do I:] The AJAX Toolkit Reorder Control</description><language>en</language><atom:link href="http://www.asp.net/rss/comments/33589" rel="self" type="application/rss+xml" /><item><title>Comment Posted by The_ASP_KID</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Mon, 12 May 2008 13:20:32 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001775</guid><description><![CDATA[ <p>Anyone know of a how-to when the user reorders the list, that list order is saved in the DB</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/The_ASP_KID.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by Wardgp</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Mon, 16 Jun 2008 16:26:37 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001776</guid><description><![CDATA[ <p>Given that a postback will reset the order of the list just exactly is the usefulness of this control? &#160;This could be a major source of user frustration.</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/Wardgp.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by richileung</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Tue, 22 Jul 2008 10:31:18 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001777</guid><description><![CDATA[ <p>I use CommandName=&quot;edit&quot; on a link button but it doesn&#39;t trigger edit event but an insert instead :( Any ideas?</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/richileung.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by fxjamy</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Fri, 25 Jul 2008 14:35:47 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001778</guid><description><![CDATA[ <p>i noticed tht too, on postback everything is set back as it was.. and is it possible to save the order in db and id we want to delete any of d item .. &#160;? ?? </p> <p>anybody ???</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/fxjamy.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by Super ASP</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Wed, 30 Jul 2008 21:21:10 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001779</guid><description><![CDATA[ <p>I noticed that it does reorder the Priority in the DB and so I just added &#160;ORDER BY PRIORITY to the end of my select statment and now it works Great. &#160;Also richileung you can use CommandName=&quot;Edit&quot; but be sure you are using it in the &lt;ItemTemplate&gt;. Hope this helps</p>]]></description><enclosure length="0" type="image/png" url="http://i1.asp.net/avatar/Super%20ASP.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by ashwinee</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Thu, 31 Jul 2008 01:54:06 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001780</guid><description><![CDATA[ <p>A very good idea &#39;Super ASP&#39; :)</p> <p>But i dint understand what is the use of the following attribute?</p> <p>ItemInsertLocation=&quot;Beginning&quot;</p> <p>(bcz if v dont do order by in select stmt then items are inserted at the end)</p> <p>Please clarify</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/ashwinee.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by Super ASP</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Fri, 01 Aug 2008 14:58:27 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001781</guid><description><![CDATA[ <p>If ItemInsertLocation=&quot;Beginning&quot;, then a new entry will get inserted at the beginning of the list. The Reorder Control will assign the new record a priority that is smaller then any other in the list. &#160;</p> <p>So if the items in your list have a priority from 0-4 then it will assign a -1</p> <p>If ItemInsertLocation is set to “End” the new entry in placed at the end of the list with a Priority greater the any in the list. </p> <p>So if the items in your list have a priority from 0-4 then it will assign a 5</p>]]></description><enclosure length="0" type="image/png" url="http://i1.asp.net/avatar/Super%20ASP.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by cv_vikram</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Thu, 07 Aug 2008 15:59:19 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001782</guid><description><![CDATA[ <p>Very good tutorial..thanks</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/cv_vikram.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by pnv.ravikiran</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Thu, 07 Aug 2008 22:31:39 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001783</guid><description><![CDATA[ <p>a nice helpful video...</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/pnv.ravikiran.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by tuhina213</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Mon, 17 Nov 2008 13:33:17 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001784</guid><description><![CDATA[ <p>Can I use Reorder List without using a SQLDataSource or ObjectDataSource? I want to bind the data in my code behind. How do I update the Ranking programatically and in which event do I do this?</p> <p>Please help.</p>]]></description><enclosure length="0" type="image/png" url="http://i1.asp.net/avatar/tuhina213.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by JimmyS</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Fri, 30 Jan 2009 04:35:31 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001785</guid><description><![CDATA[ <p>After being frustrated with trying to find a solution in vb with a sqldatasource in order to save the reordered list, I figured it out and is pretty straight forward. Here is how to do it in codebehind (for this example you must have the Reorder List AutoPostback=&quot;true&quot;). This is all done from the ItemReorder event. &#160;This may seem long but is not bad. My example uses an extra field in the database for client ID since each client has their own.</p> <p> &#160; &#160;Protected Sub ReorderList1_ItemReorder(ByVal sender As Object, ByVal e As AjaxControlToolkit.ReorderListItemReorderEventArgs) Handles ReorderList1.ItemReorder</p> <p> &#160; &#160; &#160; &#160;&#39;get Old Priority</p> <p> &#160; &#160; &#160; &#160;Dim oldI As Integer = e.OldIndex</p> <p> &#160; &#160; &#160; &#160;&#39;get New Priority</p> <p> &#160; &#160; &#160; &#160;Dim newI As Integer = e.NewIndex</p> <p> &#160; &#160; &#160; &#160;&#39;get the selected Item Value</p> <p> &#160; &#160; &#160; &#160;Dim selectedDK As String = ReorderList1.DataKeys(oldI).ToString()</p> <p> &#160; &#160; &#160; &#160;Dim i2updateList As String = &quot;&quot;</p> <p> &#160; &#160; &#160; &#160;&#39;Build update list based on everything after/equal to the new priority but not equal to the selected one and in order so they can be updated in order</p> <p> &#160; &#160; &#160; &#160;Using oConn As SqlConnection = New SqlConnection(ConfigurationManager.ConnectionStrings(&quot;ibmas terConnectionString&quot;).ConnectionString)</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;Dim sqlCmd As New SqlCommand(&quot;select id from client_todolist where id &lt;&gt; &#39;&quot; &amp; selectedDK &amp; &quot;&#39; and client_id=&#39;111193&#39; and priority &gt;= &#39;&quot; &amp; newI &amp; &quot;&#39; order by priority asc&quot;, oConn)</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;oConn.Open()</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;Using reader As SqlDataReader = sqlCmd.ExecuteReader()</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;While reader.Read()</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;If i2updateList = &quot;&quot; Then</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;i2updateList = reader(&quot;id&quot;).ToString</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;Else</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;i2updateList &amp;= &quot;,&quot; &amp; reader(&quot;id&quot;).ToString()</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;End If</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;End While</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;End Using</p> <p> &#160; &#160; &#160; &#160;End Using</p> <p> &#160; &#160; &#160; &#160;Dim newPriority As Integer = newI</p> <p> &#160; &#160; &#160; &#160;Dim rolArr As String()</p> <p> &#160; &#160; &#160; &#160;rolArr = i2updateList.Split(&quot;,&quot;)</p> <p> &#160; &#160; &#160; &#160;&#39;update each from the list by 1</p> <p> &#160; &#160; &#160; &#160;For Each x In rolArr</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;newPriority = newPriority + 1</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;Using myConnection As SqlConnection = New SqlConnection(ConfigurationManager.ConnectionStrings(&quot;ibmas terConnectionString&quot;).ConnectionString)</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;myConnection.Open()</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;Dim myCommand As SqlCommand = New SqlCommand(&quot;update client_todolist set priority = &#39;&quot; &amp; newPriority &amp; &quot;&#39; where id=&#39;&quot; &amp; x &amp; &quot;&#39;&quot;, myConnection)</p> <p> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;myCommand.ExecuteNonQuery()</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;End Using</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;newPriority = newPriority</p> <p> &#160; &#160; &#160; &#160;Next</p> <p> &#160; &#160; &#160; &#160;&#39;finally, update the selected one for its changed priority</p> <p> &#160; &#160; &#160; &#160;Using myConnection As SqlConnection = New SqlConnection(ConfigurationManager.ConnectionStrings(&quot;ibmas terConnectionString&quot;).ConnectionString)</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;myConnection.Open()</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;Dim myCommand As SqlCommand = New SqlCommand(&quot;update client_todolist set priority = &#39;&quot; &amp; newI.ToString() &amp; &quot;&#39; where id=&#39;&quot; &amp; selectedDK &amp; &quot;&#39;&quot;, myConnection)</p> <p> &#160; &#160; &#160; &#160; &#160; &#160;myCommand.ExecuteNonQuery()</p> <p> &#160; &#160; &#160; &#160;End Using</p> <p> &#160; &#160;End Sub</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/JimmyS.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by uswebpro</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Sun, 01 Feb 2009 15:28:35 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001786</guid><description><![CDATA[ <p>I agree with the top 2 comments. This video is great - but too basic. A video on how to handle updates would be nice.</p>]]></description><enclosure length="0" type="image/png" url="http://i1.asp.net/avatar/uswebpro.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by Reinaldo Ferreira</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Mon, 02 Mar 2009 13:06:38 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001787</guid><description><![CDATA[ <p>when I use the reorder list inside of modal dialog, the rectangle on reorderCue doesnt show the text inside while moving it.</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/Reinaldo%20Ferreira.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by haithemara</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Sun, 03 May 2009 07:25:02 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001788</guid><description><![CDATA[ <p>good video . Thank you Joe. I have noticed that some field such as RepeatItemCount is disabled in this control. Does anyone know how to enabled them. Also, did anyone know how to display the items in horizontal way.</p><p>Thanks</p>]]></description><enclosure length="0" type="image/png" url="http://i2.asp.net/avatar/haithemara.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by jberda</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Wed, 29 Jul 2009 14:50:30 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001789</guid><description><![CDATA[ <p>I have a parent page of items that allows you to navigate to an item detail page.  It passes the itemID to the item detail page which uses the ID in its page_load event to modify a reorderlist&#39;s select command.</p><p></p><p>The parent item page originally used Server.Transfer to navigate to the item detail page.  The reorderlist would not reorder until a postback occurred.  Then I changed the parent item page to Response.Redirect to the item detail and everything worked as I originally hoped it would.</p>]]></description><enclosure length="0" type="image/png" url="http://i1.asp.net/avatar/jberda.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by Westnyorai</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Tue, 15 Sep 2009 01:32:05 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000001790</guid><description><![CDATA[ <p>A heads up to anyone who wants to use this with XML or any non database solution. You need to create a custom class with properties then add several of the class objects to an ilist(of yourCustomClass) and bind it to the reorderlist.</p><p></p><p>Once you do that you simply class the values using the property name in place of the column name. To save the results you&#39;ll have to cycle through all of the reorderlistitem objects using a foreach loop. The trick to this is, you can&#39;t recall the property, instead you&#39;ll have to cheat a little by storing the values inside a hiddenvalue/textbox and using findcontrol to recapture the values and store them back into the xml file.</p><p></p><p>Hopefully this put you on the right track instead of having to waste a few hours figuring it out.</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/Westnyorai.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by sg48asp</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Sat, 07 Aug 2010 11:55:35 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000009786</guid><description><![CDATA[ <p>I added a delete command but can&#39;t get ito do anything. Does anyone know how to get delete to work?</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/sg48asp.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item><item><title>Comment Posted by sg48asp</title><link>http://www.asp.net/web-forms/videos/ajax-control-toolkit/how-do-i-the-ajax-toolkit-reorder-control</link><pubDate>Sat, 07 Aug 2010 13:03:53 GMT</pubDate><guid isPermaLink="false">00000000-0000-0000-000000009788</guid><description><![CDATA[ <p>I got it the delete function to work by eliminating the required field validator.</p>]]></description><enclosure length="0" type="image/png" url="http://i3.asp.net/avatar/sg48asp.jpg?forceidenticon=false&amp;dt=635046900600000000&amp;enableAvatar=False&amp;cdn_id=2013-05-10-001" /></item></channel></rss>