Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 2.0 > ASP.NET 2.0 Professional
|
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 10th, 2007, 04:52 AM
Friend of Wrox
 
Join Date: May 2006
Posts: 107
Thanks: 1
Thanked 8 Times in 7 Posts
Default Convert Windows for to Web (Treeview)

Is there a way to convert the following lines from a standalone application using treeview to a web based application?

The lines I'm having problems with are


Private Sub TreeView1_AfterSelect(ByVal sender As System.Object, ByVal e As [u]System.Windows.Forms.TreeViewEventArgs</u>) Handles TreeView1.[u]AfterSelect</u>

        Dim strTag As String
        strTag = [u]TreeView1.SelectedNode.Tag()</u>


Then later on in the code

[u]TreeView1.SelectedNode.Nodes</u>().Clear()

and

[u]oNode.Tag</u> = "L"


So my questions are what is the web equivalent of System.Windows.Forms.TreeViewEventArgs

Does it have an AfterSelect command

Can I use TreeView1.SelectedNode.Nodes

Finally is there a command for oNode.Tag

I hope someone can help me.

Thanks



__________________
Try our latest project www.nobanx.com Currency Exchange for members
 
Old April 12th, 2007, 11:07 AM
Friend of Wrox
 
Join Date: May 2006
Posts: 107
Thanks: 1
Thanked 8 Times in 7 Posts
Default

I must have been having a bad day but for the benefit of others!

Private Sub TreeView1_AfterSelect(ByVal sender As System.Object, ByVal e As System.Windows.Forms.TreeViewEventArgs) Handles TreeView1.AfterSelect
Needs to be

Public Sub TreeView1_AfterSelect(ByVal sender As Object, ByVal e As EventArgs) Handles TreeView1.SelectedNodeChanged

The other bits

strTag = TreeView1.SelectedNode.Tag()

Needs to be

strTag = TreeView1.SelectedNode.Value



And in the code for the Treeview in the .aspx page add

OnSelectedNodeChanged="TreeView1_AfterSelect"






Similar Threads
Thread Thread Starter Forum Replies Last Post
How to refresh treeview in windows form watermoon C# 0 July 18th, 2007 09:49 AM
convert web unit (pixels) to integer ubercat ASP.NET 1.0 and 1.1 Professional 0 August 8th, 2006 06:51 PM
creating Web TreeView Control dynamically in c#.ne pratik28 General .NET 0 June 22nd, 2006 07:03 AM
IE Web Control TreeView problem ... yuenyong ASP.NET 1.0 and 1.1 Basics 0 October 5th, 2005 03:04 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.