473,473 Members | 1,692 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

How to maintain state of a TreeView control

I have a TreeView control with EnableViewState = True; however, the TreeView
does not maintain its previous state on postback. Is there something else
that needs to be set up?

Thanks,

Keith
May 10 '06 #1
1 1395
Are you repopulating or rebinding (however you handle it) on every
post? I.e. in the form load event, ?

if so, make sure to check for IsPostBack (in form load) and only bind
the Tv when IsPostBack=false.

-Rick

May 10 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: | last post by:
This is a very open ended question. I have an app with a page that uses link buttons to change the display. On the prior page you have a list of objects. You click one of those objects to see it's...
1
by: R. Sammut | last post by:
Hi, I have a treeview control that is updated every 30 seconds. The treeview nodes are cleared and new nodes (same number of nodes and hierarchy) are added to the treeview. Now I need to save...
0
by: Edwin Knoppert | last post by:
I'm using a simple treeview for helpsystem. The treeview is on a masterpage, right beside it it has the container. The user uses the treeview to navigate to helppages using this masterpage. But on...
7
by: Andrew Robinson | last post by:
I have a treeview control that I use as a menu & navigation control within a master page. The nodes for this control are loaded from a database which contains the text and url of each like and the...
1
by: keithb | last post by:
Can someone provide general information on how to maintain state for a treeview control. Specifically, I need the application to maintain node expansion across postbacks. Thanks, Keith
2
by: jeff_m | last post by:
Hello, I'm having some trouble with a combination of these elements: the Session state, a Repeater control, a TreeView control, and a button. Here's the process: - User logs in (loginid...
2
by: Peter Afonin | last post by:
Hello, I've created a web application using Visual Studio 2005. I have a treeview control there. When the user expands it and clicks on the link, the treeview collapses automatically. Is it...
0
by: Mel | last post by:
I fluent in Visual Basic programming Windows applications but I am a brand new user to ASP.NET (I'm on my 3rd day now, woo hoo!). I was wondering if there is a way to remember the last state of...
1
by: Nikron | last post by:
Hi, I'm having an issue with the ASP.NET 2.0 Treeview control and persisting its' state accross requests. My Control is embedded within a master page and is used for site navigation. My problem...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.