asp.net - Change ControlParameter ControlID property from VB -


i have gridview created in asp.net within visual studio.

there control parameters in sqldatasource1 identify drop down lists editing within gridview. have "controlid" property hard coded based on name of drop down list saw in viewing source in browser:

<updateparameters> <asp:controlparameter name="origin"controlid="gridview1$ctl02$dropdownlist1" propertyname="selectedvalue" /> <asp:controlparameter name="portofload" controlid="gridview1$ctl02$dropdownlist2" propertyname="selectedvalue" /> <asp:controlparameter name="portofdischarge" controlid="gridview1$ctl02$dropdownlist3" propertyname="selectedvalue" /> <asp:controlparameter name="vessel" controlid="gridview1$ctl02$dropdownlist4" propertyname="selectedvalue" /> </updateparameters> 

currently, works when click "edit" on first row of gridview, other rows can't find id (naturally, because value put in first row). since numbers within names "gridview1$ctl02$dropdownlist1" seem incitement in pattern , want dynamically edit controlid string corresponds row "edit" button clicked in. have variable being generated based on row i'm in when edit button pressed, have no idea how dynamically update controlid property of corresponding controlparameter.

thanks


Comments

Popular posts from this blog

Android : Making Listview full screen -

javascript - Parse JSON from the body of the POST -

javascript - Chrome Extension: Interacting with iframe embedded within popup -