代码:<asp:Panel ID="picPanel" runat="server" GroupingText="图片上传" CssClass="picPanel">
<div id="panel_main1" class="panel_main" runat="server">
<div id="main1_left" class="main_left">
<asp:FileUpload ID="fileUpLoad1" runat="server" ToolTip="选择上传文件" />
<asp:TextBox ID="txtPicDesc1" runat="server" TextMode="MultiLine" Wrap="true" width="200px" height="120px" ToolTip="添加图片说明"></asp:TextBox><br />
<asp:RadioButton ID="rdoLogo1" GroupName="rdoImgType1" runat="server" Text="企业Logo" />
<asp:RadioButton ID="rdoNews1" GroupName="rdoImgType1" runat="server" Text="文章图片" /><br /> Control rdoBtnDesc = picPanel.FindControl("rdoImgType1") as RadioButton;
if (rdoBtnDesc == null)
{
Response.Write("没有数据!");
}
else
{
Response.Write(rdoBtnDesc.ID);
}
<div id="panel_main1" class="panel_main" runat="server">
<div id="main1_left" class="main_left">
<asp:FileUpload ID="fileUpLoad1" runat="server" ToolTip="选择上传文件" />
<asp:TextBox ID="txtPicDesc1" runat="server" TextMode="MultiLine" Wrap="true" width="200px" height="120px" ToolTip="添加图片说明"></asp:TextBox><br />
<asp:RadioButton ID="rdoLogo1" GroupName="rdoImgType1" runat="server" Text="企业Logo" />
<asp:RadioButton ID="rdoNews1" GroupName="rdoImgType1" runat="server" Text="文章图片" /><br /> Control rdoBtnDesc = picPanel.FindControl("rdoImgType1") as RadioButton;
if (rdoBtnDesc == null)
{
Response.Write("没有数据!");
}
else
{
Response.Write(rdoBtnDesc.ID);
}
解决方案 »
- 上传文件夹到FTP
- javascript获得dropdownlist的值
- Asp.net连接Linux环境下mysql中文显示乱码!!
- Bloo.WebControls.HtmlEditor 1.0控件发布(基于.net),欢迎下载,下载有分送哦
- SOS: 哪为兄台来救俺一命!我一定多回给分值!
- datagrid问题
- 帮帮我!
- 跪,,,跪,,,跪求思路!!!!!!!!!!!!!画曲线图!!!!!
- 急!********如何将dataGrid的所有分页面显示分页标识为 由 1 2 3 改为 -1- -2- -3-********
- 为我今天下午的精彩表现,为我多了一颗角,散分!!!
- 用jwPlayer怎么做分段截取时间循环播放的方法
- 一个正则的问题 我哪里写错了? 提取的是空的。。。
FindControl("ID") 是这个把 rdoLogo1
Control rdoBtnDesc = picPanel.FindControl("rdoLogo1") as RadioButton;
Control rdoBtnDesc1 = picPanel.FindControl("rdoNews1") as RadioButton;