日期:2014-05-18 浏览次数:20536 次
<asp:Panel ID="checkboxlist" runat="server">
<asp:Label runat="server" ID="11">办公装备</asp:Label>
<asp:RadioButtonList ID="RadioButtonList1" runat="server"
RepeatDirection="Horizontal">
<asp:ListItem Value="0">良好</asp:ListItem>
<asp:ListItem Value="1">一般</asp:ListItem>
<asp:ListItem Value="2">尚可</asp:ListItem>
</asp:RadioButtonList>
</asp:Panel>
<form id="form1" runat="server">
<asp:Panel ID="checkboxlist" runat="server">
<asp:Label runat="server" ID="lbl_1">办公装备1</asp:Label>
<asp:RadioButtonList ID="RadioButtonList1" runat="server" RepeatDirection="Horizontal">
<asp:ListItem Value="0">良好</asp:ListItem>
<asp:ListItem Value="1">一般</asp:ListItem>
<asp:ListItem Value="2">尚可</asp:ListItem>
</asp:RadioButtonList>
<asp:Label runat="server" ID="lbl_2">办公装备2</asp:Label>
<asp:RadioButtonList ID="RadioButtonList2" runat="server" RepeatDirection="Horizontal">
<asp:ListItem Value="0">良好</asp:ListItem>
<asp:ListItem Value="1">一般</asp:ListItem>
<asp:ListItem Value="2">尚可</asp:ListItem>
</asp:RadioButtonList>
</asp:Panel>
<asp:Button ID="Button1" runat="server" Text="Button" OnClick="Button1_Click" />
</form>
------解决方案--------------------
RadioButtonList radio = new RadioButtonList();
radio.EnableViewState = true;
radio.ID = dr["id"].ToString();
radio.DataSource = ds.Tables[0];
radio.DataTextField = "title";
radio.DataValueField = &quo