开发者

ASP.Net - Tree view control

I am using visual basic for coding. I drag & dropped a tree view control and edited its nodes. Now when I run my page I get this error->

Control 'TreeView1' of type 'TreeView' must be placed inside a form tag with runat=server.

In the source I have the following entry

asp:TreeView ID="TreeView1" 开发者_StackOverflow中文版runat="server" Height="155px" Style="z-index: 100; left: 41px; position: absolute; top: 108px" Width="1px" ImageSet="Contacts" NodeIndent="10"


Just place a form on the page:

so just inside the body tags add:

<body>
<form id="MainForm" runat="server">

... your form controls, including the treeview

</form>
</body>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜