8,834
社区成员
发帖
与我相关
我的任务
分享
public class OA
{
public string Name;
}
public void Page_Load()
{
Dictionary<int, OA> dict = new Dictionary<int, OA>();
for(int i =0; i<4; i++)
{
OA oa = new OA();
oa.Name = "选项"+i.ToString();
dict.Add(i,oa);
}
this.RadioButtonList1.DataSource = dict;
this.RadioButtonList1.DataTextField = ????;
this.RadioButtonList1.DataValueField = "Key";
this.RadioButtonList1.DataBind();
}