UserProfileService.AddSuggestions Method
Adds a list of suggestions with a single specified type and the specified weights for the current user.
Namespace: [UserProfileService Web service]
Web service reference: http://Site/_vti_bin/UserProfileService.asmx
Syntax
'Declaration
<SoapDocumentMethodAttribute("https://microsoft.com/webservices/SharePointPortalServer/UserProfileService/AddSuggestions", RequestNamespace := "https://microsoft.com/webservices/SharePointPortalServer/UserProfileService", _
ResponseNamespace := "https://microsoft.com/webservices/SharePointPortalServer/UserProfileService", _
Use := SoapBindingUse.Literal, ParameterStyle := SoapParameterStyle.Wrapped)> _
Public Sub AddSuggestions ( _
type As SuggestionType, _
suggestions As String(), _
weights As Double() _
)
'Usage
Dim instance As UserProfileService
Dim type As SuggestionType
Dim suggestions As String()
Dim weights As Double()
instance.AddSuggestions(type, suggestions, _
weights)
[SoapDocumentMethodAttribute("https://microsoft.com/webservices/SharePointPortalServer/UserProfileService/AddSuggestions", RequestNamespace = "https://microsoft.com/webservices/SharePointPortalServer/UserProfileService",
ResponseNamespace = "https://microsoft.com/webservices/SharePointPortalServer/UserProfileService",
Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public void AddSuggestions(
SuggestionType type,
string[] suggestions,
double[] weights
)
Parameters
type
Type: [UserProfileService Web service].SuggestionTypeThe type of suggestions to add.
suggestions
Type: []An array of suggestions to add.
weights
Type: []An array of weights for the suggestions.
Exceptions
Exception | Condition |
---|---|
SoapException | The list cannot be added. |
Remarks
This method retrieves the users’ account names from user profiles if the suggestions are given by email addresses, and then adds the list of suggestions with the same specified suggestion type and the specified weights to the suggestions of the current user.