PasswordBoxExtend Class

Extends PasswordBox with 2 attached properties that allows binding of the password.

Definition

Namespace: Common.Wpf.Controls
Assembly: Common.Wpf.Controls (in Common.Wpf.Controls.dll) Version: 2.0.7
C#
public static class PasswordBoxExtend
Inheritance
Object    PasswordBoxExtend

Remarks

1. Add a namespace attribute to the root element of the markup file it is to be used in:
XAML
xmlns:cc="clr-namespace:Common.Wpf.Controls;assembly=Common.Wpf.Controls"
2. Define the PasswordBox control specifying to bind the password:
XAML
<PasswordBox cc:PasswordBoxExtend.BindPassword="True"... >
  <cc:PasswordBoxExtend.BoundPassword>
    <Binding Path="Password" Mode="TwoWay" UpdateSourceTrigger="PropertyChanged"/> 
  </cc:PasswordBoxExtend.BoundPassword>
</PasswordBox>

Methods

GetBindPasswordGets the Bind Password property.
GetBoundPasswordGets the Bound Password property.
SetBindPasswordSets the Bind Password property.
SetBoundPasswordSets the Bound Password property.

Fields

BindPasswordIdentifies the BindPassword dependency property.
BoundPasswordIdentifies the BoundPassword dependency property.

See Also