Bagikan melalui


ProfileService.SetPropertiesForCurrentUser Metode

Definisi

Mengatur nilai properti yang ditentukan di profil pengguna.

public:
 System::Collections::ObjectModel::Collection<System::String ^> ^ SetPropertiesForCurrentUser(System::Collections::Generic::IDictionary<System::String ^, System::Object ^> ^ values, bool authenticatedUserOnly);
[System.ServiceModel.OperationContract]
public System.Collections.ObjectModel.Collection<string> SetPropertiesForCurrentUser(System.Collections.Generic.IDictionary<string,object> values, bool authenticatedUserOnly);
[<System.ServiceModel.OperationContract>]
member this.SetPropertiesForCurrentUser : System.Collections.Generic.IDictionary<string, obj> * bool -> System.Collections.ObjectModel.Collection<string>
Public Function SetPropertiesForCurrentUser (values As IDictionary(Of String, Object), authenticatedUserOnly As Boolean) As Collection(Of String)

Parameter

values
IDictionary<String,Object>

Kumpulan yang berisi nama dan nilai properti profil yang akan diatur.

authenticatedUserOnly
Boolean

Nilai yang menunjukkan apakah properti diatur hanya untuk pengguna yang telah diautentikasi.

Mengembalikan

Properti yang tidak diatur untuk profil pengguna, jika ada.

Atribut

Keterangan

Anda menggunakan SetPropertiesForCurrentUser metode untuk mengatur properti profil pengguna dari aplikasi yang kompatibel dengan Windows Communication Foundation (WCF). Metode ini SetPropertiesForCurrentUser mengembalikan nilai apa pun yang tidak ditetapkan, yang mungkin karena salah satu alasan berikut:

  • Properti profil yang ditentukan hanya dibaca ( WriteAccessProperties properti untuk properti profil tertentu tidak diatur ke true).

  • Profil pengguna tidak memiliki properti profil yang memiliki nama yang cocok.

  • Validasi nilai gagal.

Berlaku untuk