Click to See Complete Forum and Search --> : Can I use TreeView (IE Web Controls) in a Web Service Application?


Math Slavo
January 29th, 2005, 10:06 AM
Hello,

I have a Web Service Application. I need to use a Web Control, the Treeview. But in a Web Service Application, I only can view the Treeview that is in Windows Forms but I donīt want it.
I need the Web Control because I want to use the properties: TreeNodeSrc, TreeNodeXsltSrc, ...
I have installed the IE Web Controls, and in the directory /bin of my application I have the Microsoft.Web.UI.WebControls.dll that is necessary for the TreeView Control.
If I declare a treeview in my Web Service application, as following:
protected Microsoft.Web.UI.WebControls.TreeView Tree;
I receive the error:
The type or name space 'Web' doesnīt exist in the class or name space 'Microsoft'.
In a Web Application this control works good, without errors..

How can I use a TreeView Web Control in a Web Service Application?

Thanks in advance

JetDeveloper
January 29th, 2005, 12:11 PM
Goto Add References on the menu and see if you can add a reference to

Microsoft.Web.UI.WebControls

Math Slavo
January 30th, 2005, 04:56 AM
Hello,

Thanks, I have added the reference to Microsoft.Web.UI.WebControls, and now it works good.

Bye