Solved

How to do the data sorting by dragging to the desired position in asp.net, c# and Jquery?

Posted on 2012-04-04
5
217 Views
Last Modified: 2012-06-27
Hi,

I have list of product items.Product items are coming from the sql server table.

Before dragging, product items display in the below order:
Product One
Product Two
Product Three
Product Four

After dragging, product items display in the following order:
Product One
Product Four
Product Two
Product Three

We need to save the sorting order in the table. How this can be achieved by asp.net, c# and jquery?
0
Comment
Question by:Saroj13
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 23

Expert Comment

by:Christopher Kile
ID: 37814159
You will need to be able to save an index value that is associated with a table row.  This may mean that you have to create a table that specifically maintains display order information, or you may be able to add this index value to the actual data row that you want to display.  Do you understand what I mean?  If so, do you know which you would be able to do?
0
 

Author Comment

by:Saroj13
ID: 37814454
You will need to be able to save an index value that is associated with a table row.  This may mean that you have to create a table that specifically maintains display order information,
0
 
LVL 23

Expert Comment

by:Christopher Kile
ID: 37823669
I'm sorry, I only got part of your response, everything after the part where you quote me as saying "...that specifically maintains display order information"  Could you resend that, please? Thanks.
0
 

Author Comment

by:Saroj13
ID: 37824228
Hi,

On Page load, I am going to display product list according to the datetime.
I have sql server table that stores the following information: product names, order.

User can do the sorting by dragging the rows. This information will be saved in the table.
That means, we have to create a table that specifically maintains display order information.

How this can be done in asp.net, c#, jquery?
0
 
LVL 23

Accepted Solution

by:
Christopher Kile earned 500 total points
ID: 37853389
Do you intend that the user's sort selections should be maintained from session to session?  That is, the next time the user opens the site, the sort choices he had before are still active?  OR, do you just want the sort choices made by the user to be active for the current session, disappearing once the user closes the browser window?  It will make a big difference in what you will have to do.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

729 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question