Click here to Skip to main content
16,004,833 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi

In my page i Have a GridView In this i have 10 rows .

if i select 5 th row and 7th row checkboxes i want this rows Sort order on top

remaining rows after this rows can u help how to do this sorting in gridvew.
Posted
Updated 8-Jun-12 1:17am
v3
Comments
Sandeep Mewara 8-Jun-12 7:17am    
Not clear what are you trying to achieve nor the UI are referring to achieve it.
Prasad_Kulkarni 8-Jun-12 7:23am    
Please elaborate some more
MAKReddy 8-Jun-12 7:31am    
Hi In My grid i HAVE 10 rows in that if i will select 2 rows checkboxes that 2 rows should come order top remaining after that rows.
5th row 1st
7th row 2nd
1st row 3rd
2nd row 4th like this order i want.
MAKReddy 8-Jun-12 7:31am    
selected 2 rows is 5th and 7th.

1 solution

You can make it with using J query.

as shown in this demo it will use link to move the row of table to up and down.
as you know that after rendering the gridview it will become html table. so this will work with your code to move selected row to up.

you need to change this code as per your requirement to achieve your goal...

the demo is available here....

GridView Row Move Demo[^]
 
Share this answer
 
Comments
MAKReddy 8-Jun-12 7:32am    
thanks. i want in Code behind code like c# or vb

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900