Share via


PublishingService.GetFriendlyUrlBasedWebs method

Returns a collection of FriendlyUrlBasedWeb objects—one for each web that contains friendly URLs.

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

Syntax

'Declaration
<WebMethodAttribute> _
Public Function GetFriendlyUrlBasedWebs ( _
    contentPartitionId As Guid, _
    ByRef pagingToken As String _
) As FriendlyUrlBasedWeb()
'Usage
Dim instance As PublishingService
Dim contentPartitionId As Guid
Dim pagingToken As String
Dim returnValue As FriendlyUrlBasedWeb()

returnValue = instance.GetFriendlyUrlBasedWebs(contentPartitionId, _
    pagingToken)
[WebMethodAttribute]
public FriendlyUrlBasedWeb[] GetFriendlyUrlBasedWebs(
    Guid contentPartitionId,
    ref string pagingToken
)

Parameters

  • contentPartitionId
    Type: System.Guid

    The ID of the content database that is being queried.

  • pagingToken
    Type: System.String

    Tracks the current page results.

Return value

Type: []
One collection of FriendlyUrlBasedWeb objects for each web that contains friendly URLs.

Remarks

There may be a large number of results that need to be returned. In that case, the results need to be chunked into pages. The pagingToken parameter is an opaque token that SharePoint Server returns to the caller of the PublishingService web service. The caller keeps calling the GetFriendlyUrlBasedWebs(System.Guid,System.String@) method with the pagingToken parameter, and SharePoint Server continues to update the paging token until the last page is reached. When the last page is reached, SharePoint Server sets it to an empty string. In the first call, the caller is supposed to set the pagingToken parameter to an empty string.

See also

Reference

PublishingService class

PublishingService members

Microsoft.SharePoint.Publishing.WebServices namespace