Как я могу сделать TextBox «полем пароля» и отображать звездочки при использовании MVVM? ⇐ C#
-
Anonymous
Как я могу сделать TextBox «полем пароля» и отображать звездочки при использовании MVVM?
How can I do this in XAML:
PSEUDO-CODE:
so that the user sees stars or dots when he is typing in the password.
I've tried various examples which suggest PasswordChar and PasswordBox but can't get these to work.
e.g. I can do this as shown here:
but I of course want to bind the Text property to my ViewModel so I can send the value the bound TextBox when the button is clicked (not working with code behind), I want to do this:
But PasswordBox doesn't have a Text property.
Источник: https://stackoverflow.com/questions/111 ... using-mvvm
How can I do this in XAML:
PSEUDO-CODE:
so that the user sees stars or dots when he is typing in the password.
I've tried various examples which suggest PasswordChar and PasswordBox but can't get these to work.
e.g. I can do this as shown here:
but I of course want to bind the Text property to my ViewModel so I can send the value the bound TextBox when the button is clicked (not working with code behind), I want to do this:
But PasswordBox doesn't have a Text property.
Источник: https://stackoverflow.com/questions/111 ... using-mvvm
Мобильная версия