Click to Rate and Give Feedback
MSDN
MSDN Library
Web Development
SharePoint 2010
SDK Documentation
AspMenu Class
AspMenu Properties
 UseSimpleRendering Property
Community Content
In this section
Statistics Annotations (1)
Collapse All/Expand All Collapse All
AspMenu..::.UseSimpleRendering Property

Controls whether to use simple unordered list-based rendering or the default Microsoft ASP.NET table-based rendering.

Namespace:  Microsoft.SharePoint.WebControls
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No
Visual Basic (Declaration)
Public Property UseSimpleRendering As Boolean
    Get
    Set
Visual Basic (Usage)
Dim instance As AspMenu
Dim value As Boolean

value = instance.UseSimpleRendering

instance.UseSimpleRendering = value
C#
public bool UseSimpleRendering { get; set; }

Property Value

Type: System..::.Boolean
true if the menu uses simple rendering; otherwise, false. The default is false.

Set this property to true to cause the menu to render as an unordered list of anchor elements that is more easily styled using cascading style sheets (CSS) and more accessible.

Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Breaks "DisappearAfter" attribute      tswaters   |   Edit   |   Show History
Using simple rendering will break the ability to use various properties still available to SharePoint:AspMenu.  Specifically:
  • "DisappearAfter" attribute is not recognized -- menu will always disapear after the default time.
  • "StaticDisplayLevels" and  "MaximumDynamicDisplayLevels"are not recognized -- all menu items are output all the time. 
Also, this isn't mentioned -- but setting UseSimpleRendering will ignore any styling and templating elements/attributes present.  This is to be expected, I think -- as the styling should be done using CSS, styling the various classes.
  • Styling attributes (i.e. StaticHoverStyle-BackColor, BackColor, etc.)
  • Templating elements (i.e.  StaticItemTemplate, DynamicItemTemplate, etc. )
Tags What's this?: Add a tag
Flag as ContentBug
Processing
© 2012 Microsoft. All rights reserved. Terms of Use | Trademarks | Privacy Statement
Page view tracker