Click here to Skip to main content
15,915,163 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
Run mode as follows

Facid 1 2 3
1 Good(dropdownlist1) Fair(dropdownlist2) Poor(dropdownlist3)
2 Good(dropdownlist4) Fair(dropdownlist5) Poor(dropdownlist6)


in Table i want to save above records as follows

Facid 1 2 3

1 Good Fair Poor
2 Good Fair Poor

for that how can i do in asp.net using csharp.

Regards,
Narasiman P.
Posted
Updated 9-Feb-14 0:22am
v2
Comments
Karthik_Mahalingam 9-Feb-14 0:50am    
what you have tried ?
post your code.

make a connection to the database and insert your details in the table like this
Insert Into Table1(Field1,Field2,Field3)values('1','2','3');
 
Share this answer
 
In GridView RowUpdating Event, find row values.

As you are having DropDownLists, so get the Selected values and then update like below...
C#
protected void YourGrid_RowUpdating(object sender, GridViewUpdateEventArgs e)
{
    DropDownList ddl = (DropDownList )YourGrid.Rows[e.RowIndex].FindControl("dropdownlist1");
    string selectedvalue = ddl.selectedvalue;
    // Find other DropDown values as above.
    // Your update code goes here
}
 
Share this answer
 
v2

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