Retrieves the parent site map node of a specific SiteMapNode object.
Public Overrides Function GetParentNode ( _ node As SiteMapNode _ ) As SiteMapNode
Dim instance As StaticSiteMapProvider Dim node As SiteMapNode Dim returnValue As SiteMapNode returnValue = instance.GetParentNode(node)
public override SiteMapNode GetParentNode( SiteMapNode node )
public: virtual SiteMapNode^ GetParentNode( SiteMapNode^ node ) override
public override function GetParentNode( node : SiteMapNode ) : SiteMapNode
node is nullNothingnullptra null reference (Nothing in Visual Basic).
The SiteMapNode objects delegate to the site map provider to keep track of their child and parent site map nodes. As a result, classes that implement a site map provider for a hierarchical site map structure, such as the StaticSiteMapProvider class, and use SiteMapNode objects to represent site map nodes, must track the hierarchical relationships of all site map nodes in order to be able to navigate an entire hierarchical tree.
If a ParentNode property is not found, the StaticSiteMapProvider class detects whether the current site map provider has a ParentProvider property. If so, the site map provider calls the GetParentNode property for the parent site map provider. This enables the scenario where the parent site map node of a site map node is maintained by a different site map provider.
The GetParentNode method calls the BuildSiteMap method internally to retrieve the SiteMapNode that represents the parent of the specified site map node. If security trimming is enabled, the site map node is returned only if the user is permitted to see it.
Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98