473,545 Members | 2,010 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ASP.NET 2.0 Tree Control and Navigation Controls - General Question

Hi.

Why is it practical to have the ASP.NET navigation controls based on
XML? I would love to just use databinding and then be able to
dynamically update the navgiation menu (e.g. for a product list).

I tried to use a dropdownlist with hyperlinks for navigation (not the
main navigation -- a navigation subset) and even a listbox, but found
it very cumbersome.

The way I figure it now, is that I have to pull the data over from Sql
Server, convert it to XML, reformat into the appropriate nodes, and the
then populate the navigaiton control..

Is there an easier way to do this? What am I missing??

Thanks in advance!
-Ranginald

Apr 13 '06 #1
2 1485
Are you talking specifically about the SiteNav/SiteMap stuff? The short
answer is that the Site Nav data store reflects well with an XML-style tree
view of your average Web site and for many applications doesnt change often,
so again lends itself well to XML. Couple that with the fact that for large
dynamic sites you can write an XSLT that auto-generates your site nav source
everytime you publish, its a good store.

There is no reason you cannot write your own SiteMap provider and hook it
up to a datastore other than an XML file. I am pretty sure there are even
samples for how to do just this and also extend the Site nav controls in
ASP.NET 2.0 (or were at one time...I wrote them!).
<da*******@gmai l.com> wrote in message
news:11******** *************@e 56g2000cwe.goog legroups.com...
Hi.

Why is it practical to have the ASP.NET navigation controls based on
XML? I would love to just use databinding and then be able to
dynamically update the navgiation menu (e.g. for a product list).

I tried to use a dropdownlist with hyperlinks for navigation (not the
main navigation -- a navigation subset) and even a listbox, but found
it very cumbersome.

The way I figure it now, is that I have to pull the data over from Sql
Server, convert it to XML, reformat into the appropriate nodes, and the
then populate the navigaiton control..

Is there an easier way to do this? What am I missing??

Thanks in advance!
-Ranginald

Apr 17 '06 #2
Yes, I was talking about the site map.
I figured it would be just easier to have a navigation asp.net
control.

I found 2 ways to solve the problem:
1. I used a dropdown list with databinding and wrote some code to pass
the parameters to open the URL

2. I used the dataset.writexm l() and added ID and URL attributes using
a sql query and treenode binding.

I guess I was hoping that I could just bind a dataset to the
TreeBindingCont rol so everything could be dynamic, but the above
methods solved the problem...

Thanks!

Apr 18 '06 #3

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

Similar topics

1
4151
by: Norman Fritag | last post by:
Hi there I have avoided to use active x controls because I thought they are causing more problems then they are doing any good. I a new application I would want to use the tree and list view control in access 2002. Prior to that I like to fine some information or here some feed back from developers who have use active x controls success...
0
2562
by: Josema | last post by:
Hi to all, I have a webform.aspx and inside i have a dropdown list with autopostback and a place holder... Depending of the selected index that the user selects in the dropdownlist i load a usercontrol into the place holder... i dont know why im getting this error:
1
1136
by: Ketchup Please | last post by:
I need to provide a view of hierarchical data to the users who need the ability to subsequently do the following: (1) add additional nodes (root and non root nodes); (2) arrange the nodes (drag and drop existing nodes to rearrange the tree) (3) specify a short bit of text that will be displayed with each node. After the user does all that,...
10
1999
by: Dan Nash | last post by:
Hi peeps.. Im using the TreeView control from IE COntrols to create a directory structure, and trying to do it recursively. The code works, but my question is simply how can I make the subdirs appear as leaves in the Tree, rather than as new branches? Here's the code..
7
10340
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 hierarchy of the menu tree. All pretty normal stuff. Is there any simple method of maintaining the expanded / collapsed state of each node as my...
3
2541
by: _DS | last post by:
Problem with mapping a directory tree to a tree control: It takes a while to recurse subdirs and map them to nodes. This is solved in some books I've seen (MacDonald, Albahari) by reading the subdir only when its node on the tree control is opened. Has anyone pre-packaged this functionality into a control?
3
4429
by: piotrek | last post by:
Hi I would like to ask you a question. Ian creating app. that download from server directory structure ( whole tree ) and those data are placed in proper places into my treeview control. I decided that the most effective way would be : When i connect to the server once, I download the list and disconnect, instead of connecting every time...
2
1012
by: davidwank | last post by:
Hi. Why is it practical to have the ASP.NET navigation controls based on XML? I would love to just use databinding and then be able to dynamically update the navgiation menu (e.g. for a product list). I tried to use a dropdownlist with hyperlinks for navigation (not the main navigation -- a navigation subset) and even a listbox, but...
3
6980
by: Caroline M | last post by:
Hi, I'm very new to windows forms and C# so this is my first post in this group :-) I have a very simple forms app with a tab control containing two tabs. Its related to football and one tab relates to players and the other tab to teams. I'm using the ErrorProvider component to display error information which I set in the Validating...
0
7406
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7660
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7431
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7761
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5976
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5337
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3444
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1888
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1020
muto222
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.