Completed
Last Updated: 01 Apr 2025 17:29 by ADMIN
Release 2025 Q2 (May)
ADMIN
Created by: Marin Bratanov
Comments: 1
Category: Navigation
Type: Bug Report
0
One workaround is to remove nodes that are not visible, e.g., in the Page_Load event:

RadNavigation1.Nodes.RemoveAll(x => !x.Visible);

Another workaround is to remove the HTML of hidden nodes. Note that this will not affect the nodes collections and they will still be present. Invoking operations or methods on such removed nodes can cause errors.

			<telerik:RadNavigation runat="server" ID="RadNavigation1" OnClientLoad="OnClientLoad">
				<Nodes>
					<telerik:NavigationNode Text="first"></telerik:NavigationNode>
					<telerik:NavigationNode Text="second" Visible="false"></telerik:NavigationNode>
					<telerik:NavigationNode Text="third"></telerik:NavigationNode>
				</Nodes>
			</telerik:RadNavigation>
			<script>
				function OnClientLoad(sender, args) {
					var nodes = sender.get_allNodes();
					var indicesToRemove = [];
					for (var i = 0; i < nodes.length; i++) {
						if (nodes[i].get_element().style.display == "none") {
							$telerik.$(nodes[i].get_element()).remove();
						}
					}
				}
			</script>
Completed
Last Updated: 15 Mar 2016 15:42 by ADMIN
Completed
Last Updated: 23 Apr 2015 14:15 by ADMIN