다음을 통해 공유


SocialDataService.CountCommentsOfUser Method

Gets the count of all social comments created by the specified user.

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

Syntax

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

returnValue = instance.CountCommentsOfUser(userAccountName)
[SoapDocumentMethodAttribute("https://microsoft.com/webservices/SharePointPortalServer/SocialDataService/CountCommentsOfUser", RequestNamespace = "https://microsoft.com/webservices/SharePointPortalServer/SocialDataService", 
    ResponseNamespace = "https://microsoft.com/webservices/SharePointPortalServer/SocialDataService", 
    Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public int CountCommentsOfUser(
    string userAccountName
)

Parameters

  • userAccountName
    Type: System.String

    The account name of the specified user.

Return Value

Type: System.Int32
The count of all social comments created by the specified user.

Exceptions

Exception Condition
ArgumentNullException

userAccountName is null .

UserNotFoundException

The user profile for userAccountName cannot be found.

SqlException

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

Remarks

If an error occurrs or no social comment is found, this method returns 0.

See Also

Reference

SocialDataService Class

SocialDataService Members

SocialDataService Web Service