I active coloum I use an dropdownlist box in edit mode.I want to bind that
dropdownlist to database coloum in edit mode.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Krishna GaradRank #191 · 12.8K reputationPosted Feb 2, 2011, 5:58 PM EST
Foreach(gridviewrow row in Gridview1.Rows)
{
DropDownList ddl=(DropDownList)row.FindControl("ddl");
//Bind ddl here;
}
Ketul Rathod6 reputationPosted Feb 2, 2011, 6:21 PM EST
Krishna GaradRank #191 · 12.8K reputationPosted Feb 2, 2011, 6:28 PM EST
George Onofrei56 reputationPosted Feb 2, 2011, 7:08 PM EST
vijay172 reputationPosted Feb 2, 2011, 9:20 PM EST
try this steps you have TO add this code into grid view row command properties..add dropdownlist command name IN CLIENT SIDE..
if e. commandname="Given id in client side " then
write the update sql command by selecting the field dropdown,after get the data from database load into particular field..
check the link it may useful... GRID VIEW OR CLICK HERE
Bharat Bhushan177 reputationPosted Feb 2, 2011, 9:33 PM EST
http://www.codegain.com/articles/aspnet/listcontrols/how-to-bind-dropdownlist-inside-gridview-in-aspnet.aspx
Thanx