62,243
社区成员




<%@ Page language="c#" CodeBehind="test.aspx.cs" AutoEventWireup="false" Inherits="Manoen.Web.test.temp" %>
<%@ Register TagPrefix="iewc" Namespace="Microsoft.Web.UI.WebControls" Assembly="Microsoft.Web.UI.WebControls" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>test</title>
</head>
<body>
<form id="Form1" method="post" runat="server">
<table style="width: 100%; height: 100%;">
<tr>
<td style="width:140px;height:100%;" class="borderPadding"><iewc:treeview id="tvTree" width="200px" height="100%" showtooltip="false" runat="server"> </iewc:treeview></td>
</tr>
</table>
</form>
</body>
</html>
namespace Manoen.Web.test {
using System;
using Manoen.Common;
using Manoen.SRM;
using Microsoft.Web.UI.WebControls;
public partial class temp : System.Web.UI.Page {
public string UsernamePwdRequired = string.Empty;
public string t3 = string.Empty;
protected Microsoft.Web.UI.WebControls.TreeView tvTree;
public temp() {
}
//#region 窗体设计代码
protected override void OnInit(EventArgs e) {
this.InitializeComponent();
base.OnInit(e);
}
private void InitializeComponent() {
base.Load += new EventHandler(this.Page_Load);
}
//#endregion
private void Page_Load(object sender, EventArgs e) {
this.InitText();
}
private void InitText() {
//Msg.Alert("哈哈lll");
//dzd sd = new Manoen.SRM.dzd();
Microsoft.Web.UI.WebControls.TreeNode root = new Microsoft.Web.UI.WebControls.TreeNode();
root.ID = "0";
root.Text = "列表";
root.Expanded = true;
this.tvTree.Nodes.Add(root);
for (int i = 0; i < 10; i++) {
Microsoft.Web.UI.WebControls.TreeNode node = new Microsoft.Web.UI.WebControls.TreeNode();
node.ID = i.ToString();
node.Text = i.ToString() + "kdkd";
root.Nodes.Add(node);
}
}
}
}