Step 1
Modify web. config
<? XML version = "1.0" encoding = "UTF-8"?>
<Configuration>
<Configsections>
<Section name = "microsoftwebcontrols" type = "system. configuration. namevaluesectionhandler, system, version = 1.0.5000.0, culture = neutral, publickeytoken = b77a5c561934e089"/>
</Configsections>
<Microsoftwebcontrols>
<Add key = "commonfiles" value = "treepath"/>
</Microsoftwebcontrols>
<System. Web>
...................................
Step 2: Add the following statement to the page where you want to use this control
<% @ Import namespace = "Microsoft. Web. UI. webcontrols" %>
<% @ Register tagprefix = "iecontrols"
Namespace = "Microsoft. Web. UI. webcontrols"
Assembly = "Microsoft. Web. UI. webcontrols"
%>
runat = "server">
3
change the property of the control to null (go to the design page and right-click the control-> properties) systemimagespath
4,
Create a New treepath directory on the website
upload files in C:/program files/ie Web controls/build/runtime to the directory
5,
WriteCode
This. tvbasic. nodes. Clear ();
Treenode Tn = new treenode ();
Tn. Text = "nodes level1 ";
Tvbasic. nodes. Add (TN );
Treenode TN2 = new treenode ();
Tn2.text = "level2 ";
Tvbasic. nodes. Add (TN2 );
Treenode tn3 = new treenode ();
Tn3.text = "level3 ";
Tn. nodes. Add (tn3 );
Other visibility
Http://www.cnblogs.com/adandelion/archive/2005/09/13/235681.html