.NET Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsProgramming.NET Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old May 26th, 2006, 12:58 AM
dhj dhj is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: May 2006
Posts: 2 dhj User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 23 m 46 sec
Reputation Power: 0
SelectedIndexChange event is not working in Microsoft.Web.UI.WebControls treeview

I'm using a Microsoft.Web.UI.WebControls treeview in my web application (ASP.NET 1.1). It is working fine and i have built a tree with data.

Now i need to load some pages according to the node which user clicks.

I'm not able to get selected node details. There's a event called "SelectedIndexChange". But it is not firing properly when i clicked on tree nodes.

Any one over there who used it??? or any ideas???

Thank you very much in advance..

Reply With Quote
  #2  
Old May 29th, 2006, 06:24 AM
ashishdh ashishdh is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: May 2006
Posts: 37 ashishdh User rank is Lance Corporal (50 - 100 Reputation Level)ashishdh User rank is Lance Corporal (50 - 100 Reputation Level)ashishdh User rank is Lance Corporal (50 - 100 Reputation Level) 
Time spent in forums: 20 h 48 m 28 sec
Reputation Power: 4
Hi,
I am also doing R&D on TreeView but could notdo in ASP.NET1.1.How did u do.Please tell.
I will do and then I can check ur problem.
Thanks

Quote:
Originally Posted by dhj
I'm using a Microsoft.Web.UI.WebControls treeview in my web application (ASP.NET 1.1). It is working fine and i have built a tree with data.

Now i need to load some pages according to the node which user clicks.

I'm not able to get selected node details. There's a event called "SelectedIndexChange". But it is not firing properly when i clicked on tree nodes.

Any one over there who used it??? or any ideas???

Thank you very much in advance..

Reply With Quote
  #3  
Old May 29th, 2006, 08:27 PM
kboek's Avatar
kboek kboek is offline
Consuming Human
ASP Free Novice (500 - 999 posts)
 
Join Date: Nov 2003
Location: Norway
Posts: 849 kboek User rank is Second Lieutenant (5000 - 10000 Reputation Level)kboek User rank is Second Lieutenant (5000 - 10000 Reputation Level)kboek User rank is Second Lieutenant (5000 - 10000 Reputation Level)kboek User rank is Second Lieutenant (5000 - 10000 Reputation Level)kboek User rank is Second Lieutenant (5000 - 10000 Reputation Level)kboek User rank is Second Lieutenant (5000 - 10000 Reputation Level)kboek User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 1 Week 16 h 47 m 4 sec
Reputation Power: 105
Send a message via MSN to kboek
Facebook
Quote:
Originally Posted by dhj
I'm using a Microsoft.Web.UI.WebControls treeview in my web application (ASP.NET 1.1).
As far as I know, .NET 1.1 doesn't have a System.Web.UI.WebControls.TreeView Class, this class was first added to the FrameWork in .NET 2.0

So, either you're using .NET 2.0, or you're using another TreeView control (which might be from Microsoft itself as well, I vaguely remember they had some TreeView Control on www.asp.net before)

Please specify which TreeView you use, so that we can try to help you in an efficient way.
__________________
Solutions brought to you by Raskenlund ICT & Media

Reply With Quote
  #4  
Old June 12th, 2006, 12:56 AM
dhj dhj is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: May 2006
Posts: 2 dhj User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 23 m 46 sec
Reputation Power: 0
hi
thank you very much for replying my post.
yes .NET 2.0 only have the in built web tree view control

I’ll brief u my problem. so then both of u can get a idea what i have been doing.

I’m developing a web application using ASP.NET 1.1(VB). Since there is no inbuilt tree view component for web applications in .NET 1.1 I’m using Microsoft.Web.UI.WebControls.TreeView control. I have successfully bound data which retrieved from database. Now I need to do an operation (display another set of data in a separate grid) based on the tree node which user selects. So I have written my code for SelectedIndexChanged. My problem is this event is not firing properly.


This is my aspx file.

<iewc:treeview id="trvCategory" runat="server" AutoPostBack=true>

<iewc:TreeNode Text="Category" Expanded="true" />

</iewc:treeview>

This is my Page_Load

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

If Not Page.IsPostBack Then

LoadTree()

End If

End Sub


And This is my SelectIndexChanged event

Public Sub trvCategory_SelectedIndexChange(ByVal sender As Object, ByVal e As Microsoft.Web.UI.WebControls.TreeViewSelectEventAr gs) Handles trvCategory.SelectedIndexChange

‘MY CODE

End Sub


I have tried all following methods too.

I found that I should create handler separately so I add following line in page_load

AddHandler trvCategory.SelectedIndexChange, AddressOf trvCategory_SelectedIndexChange

And in another article asked to do above in InitializeComponent

And I have done following as well

<iewc:treeview id=" trvCategory " runat="server" onSelectedIndexChanged="trvCategory_SelectedIndexChange" AutoPostBack=true>

<iewc:TreeNode Text="Category" Expanded="true" />

</iewc:treeview>


But none of these are working.

If u can give me a solution that’ll be a great help

Thank you very much

Reply With Quote
Reply

Viewing: ASP Free ForumsProgramming.NET Development > SelectedIndexChange event is not working in Microsoft.Web.UI.WebControls treeview


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump





 Free IT White Papers!
 
How to Present Effectively Online
This white paper offers practical and actionable advice on the key steps that any presenter should consider as they plan and execute a Webinar or online meeting.

 
Open Source Security Myths
Open Source Software (OSS) is computer software whose source code is available to the general public with relaxed or non-existent intellectual property restrictions (or arrangement such as the public domain), and is usually developed with the input of many contributors.

 
Power and Cooling Capacity Management for Data Centers
This paper describes the principles for achieving power and cooling capacity management.

 
Scalable, Fault-Tolerant NAS for Oracle - The Next Generation
For several years NAS has been evolving as a storage alternative for Oracle databases, and for good reason: NAS is quite often the simplest, most cost-effective storage approach for Oracle. Learn about the benefits that HP's approach to scalable NAS brings to Oracle environments in this comprehensive white paper.

 
Understanding Web Application Security Challenges
This white paper discusses many common threats and preventive measures for Web application security, and explains what you can do to help protect your organization.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 Hosted by Hostway
Stay green...Green IT