推荐于2016-04-24
展开全部
protected void TreeView1_SelectedNodeChanged(object sender, EventArgs e)
{
Response.Write(TreeView1.SelectedNode.Value);
}
protected void Button1_Click(object sender, EventArgs e)
{
if(TreeView1.SelectedNode!=null)
Response.Write("获取当前节点的value:" + TreeView1.SelectedNode.Value);
}
{
Response.Write(TreeView1.SelectedNode.Value);
}
protected void Button1_Click(object sender, EventArgs e)
{
if(TreeView1.SelectedNode!=null)
Response.Write("获取当前节点的value:" + TreeView1.SelectedNode.Value);
}
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
2013-04-05
展开全部
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsFormsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
this.listBox1.Items.Clear();
foreach(TreeNode x in this.treeView1.SelectedNode.Nodes)
{
this.listBox1.Items.Add(x.Text );
}
}
}
}
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsFormsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
this.listBox1.Items.Clear();
foreach(TreeNode x in this.treeView1.SelectedNode.Nodes)
{
this.listBox1.Items.Add(x.Text );
}
}
}
}
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询