How to navigate WebMenu recursively

Document Type:

 Informational

WebMenu for ASP

Product Name:

 WebMenu for ASP

Product Versions:   

 5.0

Last Reviewed:

 1/9/2009

Document ID:

 236

Summary

Explains how to navigate WebMenu’s hierarchy and gives a sample for building a sitemap page.

Details

WebMenu exposes a hierarchical object model to allow you to configure your menu. Sometimes, your application may need to manipulate these objects to customize the menu for your users. This is especially helpful if your menu is loaded from a *.wms file created with WebMenu Studio.

If you need to manipulate WebMenu’s objects, it is recommended that you use a recursive algorithm to perform the task. Recursive logic contains functions that call themselves, and are useful when navigating a hierarchy. It allows you to walk through the hierarchy in a clear and concise manner.

To demonstrate using recursion to navigate WebMenu, we wrote the following sample applications. They are written for JScript and VBScript. These samples create a WebMenu control, and load its state from a *.wms file. Then, they use a recursive algorithm to visit all the group and item objects contained in the control. To see the results, the caption properties are written to the page to build a basic site map.

Download the sample

Coalesys Newsfeed News Archive

11/18/2009 - Update: WebMenu v5.0.96 and PanelBar v4.0.96 (All Platforms)

3/19/2009 - Windows Internet Explorer 8 released, supported by Coalesys DHTML products.

11/9/2008 - Update: Mercury-UI (All Platforms)

10/12/2008 - New Release: WebMenu v5.0.94.x (All Platforms)