CodeVerge.Net Beta


   Explore    Item Entry   Register  Login  
web_forms
getting_started
data_presentation_controls
dotnetnuke
data_access-sql_server_sql_server_express_and_sqldatasource_control
security
client_side_web_development
novell-support-groupwise-6x-clients
data_access-data_access_and_objectdatasource_control
asp-net_ajax-asp-net_ajax_control_toolkit
novell-support-netware-6x-install-upgrade
asp-net_ajax-asp-net_ajax_discussion_and_suggestions
novell-support-netware-6x-administration-tools
master_pages_themes_and_navigation_controls
configuration_and_deployment
novell-support-netware-client-winnt-2x-xp
novell-support-groupwise-7x-clients
asp-net_ajax-asp-net_ajax_ui
novell-support-edirectory-netware
community-free_for_all
visual_studio_2005
novell-support-groupwise-6x-install-setup
data_access-xml_and_xmldatasource_control
control-cancel
novell-support-iprint
advanced_asp-net-crystal_reports
data_access-xml_web_services
microsoft-public-access
novell-community-chat
state_management
novell-support-netware-6x-abends-hangs
dotnetnuke-getting_started
novell-support-groupwise-6x-gwia
-net_languages-c
novell-support-identity-manager-engine-drivers
novell-support-groupwise-discontinued
advanced_asp-net-architecture
opensuse-org-suse-linux-support-install-configure-administration
dotnetnuke-custom_modules
novell-support-groupwise-7x-install-setup-admin
novell-support-netware-6x-storage-media
novell-support-groupwise-6x-agents
installation_and_setup
data_access-access_databases_and_accessdatasource_control
windows-hosting_open_forum
visual_web_developer_2005_express
novell-support-groupwise-6x-web-access
novell-support-netware-6x-server-backup
macromedia-dreamweaver
novell-support-netware-5x-administration-tools
novell-support-ifolder
novell-support-bordermanager-install-setup
novell-support-imanager
microsoft-public-dotnet-framework-aspnet
novell-support-netware-5x-install-upgrade
novell-support-cluster-services
novell-support-bordermanager-proxies
novell-support-newsflash
advanced_asp-net-sql_server_reporting_services
microsoft-public-dotnet-languages-csharp
web_parts_and_personalization
about_this_site-feedback_on_this_website
ibm-software-websphere-portal-server
novell-support-netware-dns-dhcp
novell-support-zenworks-desktops-4x-app-launcher
-net_languages-visual_basic_-net
advanced_asp-net-custom_server_controls
novell-support-bordermanager-vpn
novell-support-ndps-neps
microsoft-public-sqlserver-programming
novell-support-netware-webserver
community-jobs
novell-support-netware-4x
advanced_asp-net-mobile_and_handheld_devices
internet_explorer_web_controls
novell-support-zenworks-desktops-4x-install-setup
novell-support-edirectory-linux
novell-support-groupwise-7x-gwia
development_tools-web_matrix_general_discussions
microsoft-public-access-formscoding
macromedia-flash
community-announcements
portal_starter_kit
novell-support-zenworks-desktops-4x-management-agent
novell-support-zenworks-patch-management
novell-support-native-file-access
microsoft-public-access-queries
microsoft-public-access-forms
novell-support-groupwise-7x-web-access
novell-support-netware-small-business-6x
data_access-active_directory_and_ldap
novell-support-edirectory-windows
novell-support-groupwise-7x-agents
novell-support-ichain
data_access-oracle
novell-support-zenworks-desktop-management-6x-imaging
novell-support-groupwise-7x-wireless
novell-support-netware-5x-abends-hangs
advanced_asp-net-localization
novell-support-zenworks-desktop-management-7x-imaging-server-nw-win




Can Reply:  No Members Can Edit: No Online: Yes
Zone: > Asp.Net Forum > general_asp.net.master_pages_themes_and_navigation_controls Tags:
Item Type: Date Entered: 2/23/2007 9:00:47 AM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
NR
XPoints: N/A Replies: 2 Views: 45 Favorited: 0 Favorite
3 Items, 1 Pages 1 |< << Go >> >|
"Kalhel" <>
NewsGroup User
Treeview, direct link to a node: how to?2/23/2007 9:00:47 AM

0

I wrote a piece of code based on the "populate on demand" example taken from the quickstart package.

The datas come from SQL server (auto refer table with parentId and NodeId), and for each node I have a Title and a detail. When I click a node, I read those values from the database. Everything is working as expected.

Now... moving the mouse over any node of the treeview, I get a link like "__dopostback(blahblahblah...)" which of course make sense.

It does not make sense if I want to create a "browsable" link to that node. I mean.... how can I create a valid link to a node xyz and be able to server side browse the table structure in order to reach that node?

Treeview Example

Root
   +   Folder1
           -   Leaf 1
           -   Leaf 2
           -   Leaf 3

If I right click "Leaf 2" and click the context menu item "Copy Link", I get a "no-sense" link to a user.
The user cannot use that link and send it to someone else, say by e-mail, cause that link is a postback instruction.

 Should I use the sitemapdatasource thingie? I have no idea, went through it but had no clue of how to use it binding the control to a database (don't even know if I can do that)

I tried to build a link on my own which could make sense, using the valuepath. The findNode function does not work (I wonder if the problem is the load on demand) and now an idea comes up: is it some events that I should hook somewhere?

That's it, if anyone has a tip would be welcome.

Cheer

"Zhao Ji Ma - M
NewsGroup User
Re: Treeview, direct link to a node: how to?3/1/2007 9:18:16 AM

0

Hi,

If a node's PopulateOnDemand property is set to true, the node is populated at run time through a postback event when the node is expanded. However this requires javascript to support this kind dynamic node population:

"__dopostback(blahblahblah...)"

This is why the URL is something like __dopostbak.

 

In your example, you can have the PopulateOnDemand property of Folder1 set to true to enable populate on demand feature. But you can disable this feature on the leaf node to make them render differently.

Root
   +   Folder1
           -   Leaf 1
           -   Leaf 2
           -   Leaf 3

 

In the TreeNodePopulate event which populate a node dynamically. You can add a dynamical node to Folder1 node like this:

NewNode.PopulateOnDemand = False
 
Hope it helps!

Zhao Ji Ma
Sincerely,
Microsoft Online Community Support

?Please remember to click ?Mark as Answer? on the post that helps you, and to click ?Unmark as Answer? if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. ?
"Kalhel" <>
NewsGroup User
Re: Treeview, direct link to a node: how to?3/5/2007 5:26:43 PM

0

hmm, ok, this is exactly what I currently do.

My question was a bit more complicated.

I would like to be able to have a link which "make sense" from a standard web link point of view.

In other words, if I'm on the node which I can describe as having the valuepath equal to 1\5\46\265, I would like to know if is there a way to automatically set a web link which the user can reuse later to reach that node once again, says a few hours later or even days later.

standard link

javascript:__doPostBack('ctl00$ContentPlaceHolder1$spl1$ctl00$ctl01$TreeView1','s0\\1\\10')

"make sense" link

 http://somethinghere/treeview.aspx?mypath=0\\1\\10

 make sense?

I guess this is not really comprehensible...

3 Items, 1 Pages 1 |< << Go >> >|


Free Download:













master/child page postback event

how to set navigationurl for treeview dynamically?

make properties of a control on masterpage public?

asp:menu and dropshadow

passing values from page to masterpage

findcontrol, asp:content, and master pages

asp menu shows fine on ie6 but not on ie7 or firefox

protect folders and nodes by role

inheriting master content page

menu subitems being hid

load xmlsitemap from stream?

adding a style to a button tag

how to load a particular node as collapsed in treeview

printing in .net

using menu control

mast page images missing

how to set theme for the whole web application instead of a single web page

skin applied to late!

source code for xmlsitemapprovider, staticsitemapprovider, and other providers availible for download.

using the menu control with a role provider or a custom sitemapprovoder

treeview - customize appearance to have a separator line between top nodes

center usercontrol in placeholder

hide root node with xmldatasource and menu

master pages and frames

site maps and query strings

where is the theme gallery?

how to set css class of body in code?

error - - compilation error, element 'accordionpane' is not a known element.

problem with the master page

using wildcards in sitemap when doing url-rewriting and using menu-control

master page properties

master page with 2 user control, adjust one uc from the other

generate aspmenu to js file

changing appearance of sitemap powered menu control

sitemapnode attribute - access denied

database menu

customizing the asp.net calendar

searching all controls in content page

change theme dynamically on multiple master pages...

passing information between pages & querying databases?

postback master/inner page, veeery confusing

sitemap provider sample

menu selected item

path source in javascript ?

user specific themes?

my pages created with my master page template are not coming out right(specifically the first <tr><td> tags in my code; the height is an inch bigger)

how to access marquee tag in content page??

how do i access public property in nested masterpage?

how to access menu item selected in master page from within a content page

checkbox tooltip in treeview

 
Search This Site:

 
  Privacy | Contact Us
All Times Are GMT