how to move selected row up and down in datagrid by clicking on button in vs2005?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dnb
    New Member
    • Jan 2008
    • 34

    #1

    how to move selected row up and down in datagrid by clicking on button in vs2005?

    Hi friends,
    I m using datagrid in vs2005.
    A datagrid that have number of rows. when the specific row is selected it should be able to move up or down by clicking UP and Down button Respectively.
    Plz help me...
  • Curtis Rutland
    Recognized Expert Specialist
    • Apr 2008
    • 3264

    #2
    What have you tried? If you post what you have tried and what you are having problems with, then we can help. But you can't just give us a scenario and expect us to write your code for you.

    Comment

    • Frinavale
      Recognized Expert Expert
      • Oct 2006
      • 9749

      #3
      Originally posted by dnb
      Hi friends,
      I m using datagrid in vs2005.
      A datagrid that have number of rows. when the specific row is selected it should be able to move up or down by clicking UP and Down button Respectively.
      Plz help me...
      You need to edit your DataGrid's DataSource to display the row in a different location.

      For instance if you're using a DataView as your DataSource for your GridView you would edit the DataView to move the rows' position up or down.

      -Frinny

      Comment

      • dnb
        New Member
        • Jan 2008
        • 34

        #4
        Originally posted by Frinavale
        You need to edit your DataGrid's DataSource to display the row in a different location.

        For instance if you're using a DataView as your DataSource for your GridView you would edit the DataView to move the rows' position up or down.

        -Frinny
        Hi
        I m creating project in VB.Net. I am using datagridview in this. I am filling datagridview from datasource. i want a code for " when i click on the UP button then selected row in datagrid moves up and when i click on the DOWN button then selected row in datagrid moves down".
        plz help me.
        thanx in advance..

        Comment

        Working...