In my form i have two textboxes one add button and a datagrid inside that grid there is three template column one is a drop down list and two textbox.In the first text box i can enter value and if i press the add button it will be entered in the databse and shown in the datagrid at the same time. in the dropdown list i want the full listing of the count of rows eg: if i had five rows the values in side the dropdownlist should be like 1,2,3,4,5 like wise if i had added one more row so there is 6 now the count is 1,2,3,4,5,6 this ll be filled on each rows of the datagrid. why i am keeping this is to set the priority of the rows that are added if supose i want to display the 4th step as the 1st step i want to interchange the contents of the text boxs in both rows through the change in the value of dropdownlist