Having trouble getting help?
Contact Support
Contact Support
Events in MAUI TextInputLayout
PasswordVisibilityToggled Event
The PasswordVisibilityToggled event will be triggered whenever you toggle the password toggle icon in the SfTextInputLayout. The event arguments are of type PasswordVisibilityToggledEventArgs and expose the following property:
- IsPasswordVisible: Its value is defined based on the visibility of the password.
<inputLayout:SfTextInputLayout Hint="Password"
PasswordVisibilityToggled="OnPasswordVisibilityToggled">
<Entry Text="1234"/>
</inputLayout:SfTextInputLayout>
var inputLayout = new SfTextInputLayout();
inputLayout.Hint = "Password";
inputLayout.PasswordVisibilityToggled += OnPasswordVisibilityToggled;
inputLayout.Content = new Entry() { Text = "1234" };
private void OnPasswordVisibilityToggled(object sender, PasswordVisibilityToggledEventArgs e)
{
bool passwordVisbility = e.IsPasswordVisible;
}