0
我想從用戶控件中訪問DropDownList選定的值,該值位於Repeater的ItemTemplate
內。查找中繼器內用戶控制的下拉值asp.net
string ddlBeneficiaryTeam2 = ((UserControl_TeamFilter)(rptBeneficiaries.FindControl("ucBeneficiaryTeam"))).TeamSelectedValue;
- rptBeneficiaries -Repeater控制
- ucBeneficiaryTeam - 用戶控制
- ddlteam -DropDownList命名其在用戶控制。
我需要訪問這個ddlTeam選擇的值,這裏是控制ID:ctl00_cphMain_rptBeneficiaries_ctl00_ucBeneficiaryTeam_ddlTeam – kumarjcet