Share via


SocialDataService.GetCommentsOfUser Method

Retrieves all social comments created by a specified user, up to the specified maximum number and starting at the specified zero-based index.

Namespace:  [SocialDataService Web service]
Web service reference: http://Site/_vti_bin/SocialDataService.asmx

Syntax

'Declaration
<SoapDocumentMethodAttribute("https://microsoft.com/webservices/SharePointPortalServer/SocialDataService/GetCommentsOfUser", RequestNamespace := "https://microsoft.com/webservices/SharePointPortalServer/SocialDataService",  _
    ResponseNamespace := "https://microsoft.com/webservices/SharePointPortalServer/SocialDataService",  _
    Use := SoapBindingUse.Literal, ParameterStyle := SoapParameterStyle.Wrapped)> _
Public Function GetCommentsOfUser ( _
    userAccountName As String, _
    maximumItemsToReturn As Nullable(Of Integer), _
    startIndex As Nullable(Of Integer) _
) As SocialCommentDetail()
'Usage
Dim instance As SocialDataService
Dim userAccountName As String
Dim maximumItemsToReturn As Nullable(Of Integer)
Dim startIndex As Nullable(Of Integer)
Dim returnValue As SocialCommentDetail()

returnValue = instance.GetCommentsOfUser(userAccountName, _
    maximumItemsToReturn, startIndex)
[SoapDocumentMethodAttribute("https://microsoft.com/webservices/SharePointPortalServer/SocialDataService/GetCommentsOfUser", RequestNamespace = "https://microsoft.com/webservices/SharePointPortalServer/SocialDataService", 
    ResponseNamespace = "https://microsoft.com/webservices/SharePointPortalServer/SocialDataService", 
    Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public SocialCommentDetail[] GetCommentsOfUser(
    string userAccountName,
    Nullable<int> maximumItemsToReturn,
    Nullable<int> startIndex
)

Parameters

  • userAccountName
    Type: System.String

    The account name of the specified user.

  • maximumItemsToReturn
    Type: System.Nullable<Int32>

    The maximum number of comments to return. This value must be null , or nonnegative and less than 1001. If null or 0, this method returns up to 1000 social comments.

  • startIndex
    Type: System.Nullable<Int32>

    The zero-based index of the total set of social comments at which the returned set of social comments starts. This value must be null or nonnegative. If this value is null or 0, this method returns the set of social comments that starts with the first social comment in the total set of social comments.

Return Value

Type: []
An array that contains all social comments created by a specified user, up to the specified maximum number and starting at the specified zero-based index.

Exceptions

Exception Condition
ArgumentNullException

userAccountName is null .

UserNotFoundException

The user profile for userAccountName cannot be found.

ArgumentOutOfRangeException

maximumItemsToReturn is negative or greater than 1000, or startIndex is negative.

SqlException

The user does not have permission to access the user profile for userAccountName.

See Also

Reference

SocialDataService Class

SocialDataService Members

SocialDataService Web Service