473,387 Members | 1,492 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

C#-WEB: Ajax Reorderlist Control

daJunkCollector
Expand|Select|Wrap|Line Numbers
  1. <cc1:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server" >
  2.     </cc1:ToolkitScriptManager>
  3.         <asp:UpdatePanel ID="UpdatePanel1" runat="server">
  4.             <ContentTemplate>
  5.                 <asp:UpdateProgress ID="UpdateProgress1" runat="server">
  6.                     <ProgressTemplate>
  7.                         Processing Server Request...
  8.                     </ProgressTemplate>
  9.                 </asp:UpdateProgress>
  10.               <br />
  11.  
  12.  
  13.  
  14.               <div class="reorderListDemo">
  15.                   <cc1:ReorderList ID="ReorderList1" runat="server" 
  16.                                                   PostBackOnReorder="False"
  17.                                                   DataSourceID="SqlDataSource1"
  18.                                                   CallbackCssStyle="callbackStyle"
  19.                                                   DataKeyField="TstID"
  20.                                                   SortOrderField="TstValue"
  21.                                                   AllowReorder="true" >
  22.                       <ItemTemplate>
  23.                           <div>
  24.                               <asp:Label ID='lblNameofTeam' runat="server" Text='<%# DataBinder.Eval(Container,"DataItem.TstTitle")  %>' />
  25.                           </div>
  26.                       </ItemTemplate>
  27.                            <ReorderTemplate>
  28.                                <asp:Panel ID="Panel2" runat="server" CssClass="reorderCue" /> 
  29.                           </ReorderTemplate>
  30.                       <DragHandleTemplate>
  31.                           <div class="dragHandle">
  32.                               <img src="images/logo.gif" />
  33.                           </div>
  34.                       </DragHandleTemplate>
  35.                 </cc1:ReorderList>
  36.             </div> 
  37.             <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:WebsiteConnectionString2 %>"
  38.                                                  SelectCommand="SELECT [TstTitle],[TstValue],[TstID] FROM [Tst900]" UpdateCommand="UPDATE Tst900 SET TstValue = @TstValue where TstId=@TstId"> 
  39.                 <UpdateParameters>
  40.                     <asp:Parameter Name="@TstValue" />
  41.                     <asp:Parameter Name="@TstId" />
  42.                 </UpdateParameters>
  43.             </asp:SqlDataSource>
  44.            <asp:Button ID="Button1" runat="server" Text="Save" />
  45.      </ContentTemplate>
  46.  </asp:UpdatePanel>
The above code displays the Reorderlist Control correctly, but I cannot figure out how to then save the new order to the database. I'm sure this is fairly easy but I cannot wrap my head around it. I would prefer to add the code to the onclick of the 'save' button at the bottom. Any help would be greatly appreciated.
Dec 17 '07 #1
0 3181

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: =?Utf-8?B?R2VyaGFyZA==?= | last post by:
I am just stating to use ajax, and have a perfect place to use the accordion control. I have it working fine, but need to have a normal asp button in one of the panes that fires an onclick event...
0
by: =?Utf-8?B?d2lsbGlhbQ==?= | last post by:
Hi, I'm not sure if this is bug or not. I have a asp.net page which use AJAX CalenderExtender control for user to select a date. There is also a CrystalReportViewer control on this page, which...
1
by: JDeats | last post by:
So I'm looking for the source behind this sample: http://www.asp.net/AJAX/AjaxControlToolkit/Samples/HoverMenu/HoverMenu.aspx I want to attach a HoverMenu control to a DataGridView control and...
1
by: Joe | last post by:
I need to add a rating control to our page so I thought I would try the AJAX one. Well after making all the changes to my web.config for AJAX it turns out that the control still doesn't display. ...
4
by: Peter | last post by:
Does anyone know of OpenSource .NET 2.0 ajax dropdown box with typeahead feature and ability to load only X amount of items? I have over 20,000 names in a database table which I would like to...
1
by: Dan Bass | last post by:
I'm developing an Ajax keypad (C# / ASP.Net 3.5 / VS 2008) using the updatepanel so that a full visible postback doesn't occur with each button press. I've decided to try and wrap the...
0
by: ravindraverma | last post by:
Hi All, How Do We Use Ajax Animation Control In Asp.net 2005 With Vb Datagrid On Mouse Over Event Like Tooltip, In Animation Control We Can Show Person Detail Information On Mouse Over...
0
by: sanrek | last post by:
Hi Folks, Slider control is driving me nuts, below is the code from my test page's page load event, nothing great about code, I have a place holder control into which I am adding a table which...
3
by: usha535140 | last post by:
Hi, Can we use Ajax RoundedCornersExtender control with AJax,tabContainer?
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.