WebSecurity - CreateAccount ()
❮ WebSecurity
အဓိပ္ပါယ်
CreateAccount () နည်းလမ်းသည် အသုံးပြုသူအမည်နှင့် စကားဝှက်ကိုအသုံးပြု၍ အသုံးပြုသူဒေတာဘေ့စ်တွင် အကောင့်အသစ်တစ်ခုဖန်တီးပေးကာ အသုံးပြုသူသည် အကောင့်ကို ပြတ်သားစွာအတည်ပြုရမည်ဆိုပါက သတ်မှတ်ပေးနိုင်ပါသည်။
C# နှင့် VB Syntax
WebSecurity.CreateAccount(username,
password, requireConfirmation)
ကန့်သတ်ချက်များ
Parameter | Type | Description |
---|---|---|
userName | String | The user name |
password | String | The user password |
requireConfirmation | Boolean | true if the account must be confirmed using the token return value, default is false. |
တန်ဖိုးကို ပြန်ပေးသည်။
Type | Description |
---|---|
String | A token that can be sent to the user to confirm the account. |
အမှားများနှင့် ခြွင်းချက်များ
WebSecurity အရာဝတ္တု သို့ ဝင်ရောက်ခွင့်မှန်သမျှ သည် InvalidOperationException ကို ပစ်ချ ပါက-
- InitializeDatabaseConnection () နည်းလမ်းကို မခေါ်ဆိုပါ။
- SimpleMembership ကို စတင်ခြင်းမပြုပါ (သို့မဟုတ် ဝဘ်ဆိုဒ်ဖွဲ့စည်းပုံတွင် ပိတ်ထားသည်)
CreateAccount () နည်းလမ်းသည် အကယ်၍ MembershipCreateUserException ကို ပစ်ချသည် -
- အသုံးပြုသူအမည်သည် ဗလာဖြစ်နေသည်။
- အသုံးပြုသူအမည်တွင် အဖွဲ့ဝင်အကောင့်တစ်ခု ရှိနှင့်ပြီးဖြစ်သည်။
- စကားဝှက်သည် ဗလာဖြစ်နေသည်။
- စကားဝှက်သည် ရှည်လွန်းသည်။
- ဒေတာဘေ့စ် လုပ်ဆောင်ချက် မအောင်မြင်ပါ။
❮ WebSecurity