PasswordBox.PasswordChanged Event
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Occurs when the value of the Password property changes.
public:
event System::Windows::RoutedEventHandler ^ PasswordChanged;
public event System.Windows.RoutedEventHandler PasswordChanged;
member this.PasswordChanged : System.Windows.RoutedEventHandler
Public Custom Event PasswordChanged As RoutedEventHandler
Event Type
Examples
The following example shows how to specify the handler method for the PasswordChanged event.
<PasswordBox
Name="pwdBox"
MaxLength="64"
PasswordChar="#"
PasswordChanged="PasswordChangedHandler"
/>
The following example shows the corresponding event handler. In this case, the event handler simply increments a counter.
private int pwChanges = 0;
void PasswordChangedHandler(Object sender, RoutedEventArgs args)
{
// Increment a counter each time the event fires.
++pwChanges;
}
Private pwChanges As Integer = 0
Private Sub PasswordChangedHandler(ByVal sender As Object, ByVal args As RoutedEventArgs)
' Increment a counter each time the event fires.
pwChanges += 1
End Sub
Remarks
Routed Event Information
Identifier field | PasswordChangedEvent |
Routing strategy | Bubbling |
Delegate | RoutedEventHandler |
Applies to
Samarbejd med os på GitHub
Kilden til dette indhold kan findes på GitHub, hvor du også kan oprette og gennemse problemer og pullanmodninger. Du kan få flere oplysninger i vores vejledning til bidragydere.
Feedback
https://aka.ms/ContentUserFeedback.
Kommer snart: I hele 2024 udfaser vi GitHub-problemer som feedbackmekanisme for indhold og erstatter det med et nyt feedbacksystem. Du kan få flere oplysninger under:Indsend og få vist feedback om