DropDownList2.Attributes.Add("onchange", "changearea1()");
DataSet ds = sjAspDBMgr.OpenSQLDataSetEx("PageInfo", "SJXQWebSitePageInfo.dbo.Get_DLL", "DLL");
for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
{
DropDownList2.Items.Add(new ListItem(ds.Tables[0].Rows[i][1].ToString(),ds.Tables[0].Rows[i][2].ToString()));
}
Label1.Text = DropDownList2.Items[DropDownList2.SelectedIndex].Value;
DataSet datads = sjAspDBMgr.OpenSQLDataSetEx("PageInfo", "SJXQWebSitePageInfo.dbo.Get_DLL", "System");
for (int i = 0; i < datads.Tables[0].Rows.Count; i++)
{
DropDownList1.Items.Add(new ListItem(datads.Tables[0].Rows[i][1].ToString(),datads.Tables[0].Rows[i][1].ToString()));
}<body>
<form id="form1" runat="server">
<uc1:PageHeader ID="PageHeader1" runat="server" />
<div>
<table align="center" border="1" cellpadding="0" cellspacing="0" style="border-collapse:collapse" width="80%">
<tr>
<td class="H_Tr_L" colspan="3">
請新增這個系統會用到的dll</td>
</tr>
<tr>
<td class="H_Tr_L">
System</td>
<td colspan="2">
<asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True">
</asp:DropDownList>
<asp:Button ID="btnShan" runat="server" CommandName="delete" CssClass="btn" Text="刪除"
onclick="btnShan_Click" />
<br />
<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
<asp:Button ID="btnZeng" runat="server" Text="新增" CssClass="btn"
onclick="btnZeng_Click" />
</td>
</tr>
<tr>
<td class="H_Tr_L" rowspan="2">
User Defined</td>
<td colspan="2">
<asp:DropDownList ID="DropDownList2" runat="server" AutoPostBack="True">
</asp:DropDownList>
<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
<asp:Button ID="btnDelete" runat="server" CommandName="delete" CssClass="btn" Text="刪除"
onclick="btnDelete_Click" />
</td>
</tr>
<tr>
<td>DLLName
<asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>
</td>
<td>
DLLPath
<asp:TextBox ID="TextBox3" runat="server"></asp:TextBox>
<asp:Button ID="btnAdd" runat="server" CommandName="delete" CssClass="btn" Text="新增"
onclick="btnAdd_Click" />
</td>
</tr>
</table>
</div>
</form>
</body>
</html>
DataSet ds = sjAspDBMgr.OpenSQLDataSetEx("PageInfo", "SJXQWebSitePageInfo.dbo.Get_DLL", "DLL");
for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
{
DropDownList2.Items.Add(new ListItem(ds.Tables[0].Rows[i][1].ToString(),ds.Tables[0].Rows[i][2].ToString()));
}
Label1.Text = DropDownList2.Items[DropDownList2.SelectedIndex].Value;
DataSet datads = sjAspDBMgr.OpenSQLDataSetEx("PageInfo", "SJXQWebSitePageInfo.dbo.Get_DLL", "System");
for (int i = 0; i < datads.Tables[0].Rows.Count; i++)
{
DropDownList1.Items.Add(new ListItem(datads.Tables[0].Rows[i][1].ToString(),datads.Tables[0].Rows[i][1].ToString()));
}<body>
<form id="form1" runat="server">
<uc1:PageHeader ID="PageHeader1" runat="server" />
<div>
<table align="center" border="1" cellpadding="0" cellspacing="0" style="border-collapse:collapse" width="80%">
<tr>
<td class="H_Tr_L" colspan="3">
請新增這個系統會用到的dll</td>
</tr>
<tr>
<td class="H_Tr_L">
System</td>
<td colspan="2">
<asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True">
</asp:DropDownList>
<asp:Button ID="btnShan" runat="server" CommandName="delete" CssClass="btn" Text="刪除"
onclick="btnShan_Click" />
<br />
<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
<asp:Button ID="btnZeng" runat="server" Text="新增" CssClass="btn"
onclick="btnZeng_Click" />
</td>
</tr>
<tr>
<td class="H_Tr_L" rowspan="2">
User Defined</td>
<td colspan="2">
<asp:DropDownList ID="DropDownList2" runat="server" AutoPostBack="True">
</asp:DropDownList>
<asp:Label ID="Label1" runat="server" Text="Label"></asp:Label>
<asp:Button ID="btnDelete" runat="server" CommandName="delete" CssClass="btn" Text="刪除"
onclick="btnDelete_Click" />
</td>
</tr>
<tr>
<td>DLLName
<asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>
</td>
<td>
DLLPath
<asp:TextBox ID="TextBox3" runat="server"></asp:TextBox>
<asp:Button ID="btnAdd" runat="server" CommandName="delete" CssClass="btn" Text="新增"
onclick="btnAdd_Click" />
</td>
</tr>
</table>
</div>
</form>
</body>
</html>
解决方案 »
- The controller for path '/favicon.ico' was not found or does not implement
- .net js 数字证书 读取时
- ===============各位高手,如何解析同一个网站内其他网页的内容=================
- SQL数据库
- 两个listbox遇到问题了!!!
- 点击树结构中的叶接点怎样发生事件?
- 动态加载用户控件,为什么用户控件里的事件不能触发了?
- HELP!!!为什么我的在textbox显示的段落,第一段的文章在数据库里是空两行的,在textbox中才空一行??
- 一倍受打击的问题!望多多帮忙....(UP者给分)在线等待,及时结贴
- 关于不同目录下论坛cookies使用的问题!!
- cs文件与实现IHttpModule哪个效率高?
- 这个问题很棘手,高手帮个忙吧
看看呢,再不行,在Javascript设置断点,调试吧
</asp:DropDownList>
protected void MySelectedIndexChanged(object sender, EventArgs e)
{
// ........
}
可能是你js函数问题吧var index = document.getIlemntById("myDrop").selectedIndex;
这个是我后来用加的 用来替补的方案
我复制的时候不小心放上去了
这句话是没有的 各位大侠再看看
http://blog.csdn.net/greatverve/archive/2008/12/01/3418348.aspx
你查看一下源代码,看看究竟生成了什么东西。
lz检查下控件的autopostback是不是设置对了