急!!!在线等待:dropdownlist和treeview组合问题
希望点击dropdownlist后弹出的下拉框里面出现的是一棵树信息,点击树节点后,相应的信息进入dropdownlist,希望好心人帮忙出个主意 --------------------编程问答-------------------- http://topic.csdn.net/u/20100906/14/8f055d33-3961-4768-8b61-b3c0aaf43e96.html --------------------编程问答-------------------- 这个用JS控制也可以,用C#控制也可以,本人用C#设计一下
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>无标题页</title>
</head>
<body>
<form id="form1" runat="server">
<asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True">
<asp:ListItem>1选择</asp:ListItem>
<asp:ListItem>2选择</asp:ListItem>
</asp:DropDownList>
<asp:DropDownList ID="DropDownList2" runat="server">
</asp:DropDownList>
</form>
</body>
</html>
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
string st_name = DropDownList1.SelectedValue.ToString();
if(Equals(st_name,"1选择"))
{
//DropDownList2后台添值
}
if (Equals(st_name, "2选择"))
{
//DropDownList2后台添值
}
}
}
--------------------编程问答-------------------- 学习了 我正在找这个·
补充:.NET技术 , ASP.NET