首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > asp.net >

dropDownlist,该如何解决

2012-02-27 
dropDownlistDropDownListddlregion(DropDownList)e.Item.FindControl( drpregion )ddlregion.Selecte

dropDownlist
DropDownList   ddlregion=(DropDownList)e.Item.FindControl( "drpregion ");
ddlregion.SelectedIndexChanged   +=   new   EventHandler(this.ddlregion_change);
ViewState[ "thiscountry "]=e.Item.ItemIndex;


public   void   ddlregion_change(object   sender,   System.EventArgs   e)
{
DropDownList   Drp=(DropDownList)sender;
string   region=Drp.SelectedItem.Value;
DataGridItem   item=this.listDG.Items[(int)ViewState[ "thiscountry "]];
item.FindControl( " ");
DropDownList   ddlcountry=(DropDownList)   item.FindControl( "drpcountry ");   //(DropDownList)this.listDG.FindControl();
ddlcountry.DataSource=Components.Region.getCountryGroup(region);
ddlcountry.DataTextField= "code ";
ddlcountry.DataValueField= "region ";
ddlcountry.DataBind();
}

[解决办法]
你想干什么?
[解决办法]
怎么了?

热点排行