My treeview doesn't work...

C

Chris Hoare

I have tried to create a treeview but instead of an
explorer style screen, I get a line of text with nothing
treeview-like about it at all.

Heres my code....




<html>
<body>
<form name="Form1" method="post"
action="webform2.aspx" id="Form1">
<input type="hidden" name="__Treeview1_State__" value="" />
<input type="hidden" name="__VIEWSTATE"
value="dDwxNjkzMTE3NDIyO3Q8O2w8aTwxPjs+O2w8dDw7bDxpPDE+Oz47
bDx0PEAwPHA8cDxsPFNlbGVjdGVkTm9kZUluZGV4Oz47bDwwOz4+Oz47Ozs
7O0AwPDtAMDxsPGk8MD47PjtsPEAwPEAwPHA8bDxTZWxlY3RlZDs+O2w8bz
x0Pjs+Pjs7Ozs+Ozs+Oz47Pjs+Oz47Oz47Pj47Pj47bDxUcmVldmlldzE7P
j6WbtDyH//k5D37neLk1s9e8S6T+w==" />

<?XML:NAMESPACE PREFIX=TVNS />
<?IMPORT NAMESPACE=TVNS
IMPLEMENTATION="/webctrl_client/1_0/treeview.htc" />
<tvns:treeview id="Treeview1" NAME="Treeview1"
selectedNodeIndex="0" HelperID="__Treeview1_State__"
systemImagesPath="/webctrl_client/1_0/treeimages/"
onexpand="javascript: if (this.clickedNodeIndex != null)
this.queueEvent('onexpand', this.clickedNodeIndex)"
oncollapse="javascript: if (this.clickedNodeIndex != null)
this.queueEvent('oncollapse', this.clickedNodeIndex)"
oncheck="javascript: if (this.clickedNodeIndex != null)
this.queueEvent('oncheck', this.clickedNodeIndex)"
onselectedindexchange="javascript: if
(event.oldTreeNodeIndex != event.newTreeNodeIndex)
this.queueEvent('onselectedindexchange',
event.oldTreeNodeIndex + ',' + event.newTreeNodeIndex)">
<tvns:treenode Selected="true">
My first Tree Node<tvns:treenode>
My second Tree Node
</tvns:treenode>
</tvns:treenode>
</tvns:treeview>
</form>
</body>
</html>
 
M

MSFT

Hi Chris,

IF the IE web controls haven't beed installed correctly, there will be such
a problem. You can follow these steps to complete the installation:

To build the IE Web Controls:

1. Make sure you have installed the .NET Framework SDK v1.0 or v1.1
2. Run Build.bat, which will create a build folder in this directory.
The build folder contains Microsoft.Web.UI.WebControls.dll and a
Runtime directory of supporting files.

To run the IE Web Controls:

1. Copy the contents of the Runtime directory to the webctrl_client\1_0
directory under your top-level site directory. For example, if your
site root is c:\Inetpub\wwwroot, type this at the command prompt:

xcopy /s /i .\build\Runtime c:\Inetpub\wwwroot\webctrl_client\1_0 /y

This will create the following directory structure under the site:

/webctrl_client/1_0
MultiPage.htc
TabStrip.htc
toolbar.htc
treeview.htc
webservice.htc
webserviced.htc
[images]
[treeimages]

2. Create a new web application in IIS and copy the contents of the
samples directory to this application directory. For example:

xcopy /s /i .\samples c:\Inetpub\wwwroot\sampleapp /y

3. Create a /bin subdirectory for the application and copy the file
Microsoft.Web.UI.WebControls.dll to this directory.

The contents of the application will be as follows:

/sampleapp
multipage.aspx
state_city.xml
tabstrip.aspx
toolbar.aspx
treeview.aspx
treeview_bound.aspx
/bin
Microsoft.Web.UI.WebControls.dll

4. Request the sample pages from your Internet Explorer web browser, for
example: http://localhost/sampleapp/multipage.aspx

For additional documentation and samples visit:
http://msdn.microsoft.com/library/default.asp?url=/workshop/webcontrols/webc
ontrols_entry.asp


Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top