SocialDataService.GetRatingOfUserOnUrl method

Retrieves the social rating associated with the specified user for the specified URL.

Namespace:  WebSvcSocialDataService
Assembly:  UserProfileServices (in UserProfileServices.dll)

Syntax

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

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

Parameters

  • userAccountName
    Type: System.String

    The account name of the user associated with the social rating.

  • url
    Type: System.String

    The URL for which the social rating is retrieved. This value must be in a valid URI format and must contain fewer than 2085 characters.

Return value

Type: WebSvcSocialDataService.SocialRatingDetail
The social rating associated with the specified user for the specified URL.

Exceptions

Exception Condition
ArgumentNullException

userAccountName or url is null .

UriFormatException

url is not in the correct format.

UserNotFoundException

The user profile for userAccountName cannot be found.

SqlException

The user does not have permission to access the user profile for userAccountName or permissions to view the social ratings for userAccountName and url.

Remarks

If this method does not find any social ratings for the URL associated with the specified user, it sets the return value’s Rating() property to -1 and its LastModifiedTime property to MinValue().

See also

Reference

SocialDataService class

SocialDataService members

WebSvcSocialDataService namespace