Reputation: 2107
I need to create a checkbox that will reveal password characters in two PasswordBox controls (Password and Confirm Password respectively). So, when this checkbox is checked PasswordBox must show password instead of "*****". Actually, I'm asking about property (if it exists) that controls this behavior of PasswordBox. I didn't find it on MSDN (or didn't understand).
Upvotes: 0
Views: 2818
Reputation: 14432
For Windows Phone 8.1 (not 8.0) there is the property IsPasswordRevealButtonEnabled.
Definition:
Gets or sets a value that specifies whether the visual UI of the PasswordBox includes a button element that toggles showing or hiding the typed characters.
XAML:
<PasswordBox IsPasswordRevealButtonEnabled="bool" />
C#:
public bool IsPasswordRevealButtonEnabled { get; set; }
Upvotes: 2
Reputation: 3195
You have to use TextBox to show characters. You can put them over your PasswordBoxes and bind Text to Password and Visibility to IsChecked of CheckBox
Upvotes: 1