Share via


LevelHierarchyWebPart.LevelsToShow property

Gets or sets the number of levels to show in this Web Part.

Namespace:  Microsoft.SharePoint.Publishing.WebControls
Assembly:  Microsoft.SharePoint.Publishing (in Microsoft.SharePoint.Publishing.dll)

Syntax

'Declaration
<WebBrowsableAttribute(False)> _
<PersonalizableAttribute(PersonalizationScope.Shared)> _
Public Property LevelsToShow As Integer
    Get
    Set
'Usage
Dim instance As LevelHierarchyWebPart
Dim value As Integer

value = instance.LevelsToShow

instance.LevelsToShow = value
[WebBrowsableAttribute(false)]
[PersonalizableAttribute(PersonalizationScope.Shared)]
public int LevelsToShow { get; set; }

Property value

Type: System.Int32
An int that contains the number of levels to show in this Web Part.

Remarks

This information is passed to the LevelHierarchyDataSource to control the number of levels of data to get. The default value is 2.

See also

Reference

LevelHierarchyWebPart class

LevelHierarchyWebPart members

Microsoft.SharePoint.Publishing.WebControls namespace

LevelHierarchyDataSource