Click to Rate and Give Feedback

  Switch on low bandwidth view
Community Content
In this section
Statistics Annotations (0)
SPWeb.GetSubwebsForCurrentUser Method (Microsoft.SharePoint)
Returns the collection of subsites beneath the current Web site of which the current user is a member.
Name Description
SPWeb.GetSubwebsForCurrentUser ()
Returns the collection of subsites beneath the current site of which the current user is a member.
SPWeb.GetSubwebsForCurrentUser (Int32)
Returns the collection of subsites beneath the current Web site of which the current user is a member based on the specified site definition.
SPWeb.GetSubwebsForCurrentUser (Int32, Int16)
Returns the collection of subsites beneath the current Web site in which the current user is a member, based on the specified site definition and configuration.
Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Works only for Site Collection      Ankit Jain ... marlobello   |   Edit   |   Show History
This only works if the current SPWeb object is the RootWeb of the Site Collection.
Don;t expect any result when the current site is only a simple web.
Flag as ContentBug
Problem with Site Level Visibility with Custom Permissions      Derek Himes   |   Edit   |   Show History

Note that this will work only at the top or specified level if the user doesn't have permissions via inheritance in sharepoint.

If a user doesn't have permission at a top level site (parent) although they have permission in a subsite (child), the child will not get returned by this method.

Since the user doesn't have permission at the top level, it is hidden from the current user's context and therefore doesn't get queried by this method.

Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker