Class PasswordBoxService
Attached behavior for PasswordBox that will invoke an ICommand to send the SecureString of the SecurePassword property to a command target e.g., view model using a registered ICommand registered with the CommandProperty attached property.
Inherited Members
Namespace: BionicCode.Utilities.Net
Assembly: BionicCode.Utilities.Net.Wpf.dll
Syntax
public class PasswordBoxService : DependencyObject
Remarks
The attached behavior does at no point unwrap the the SecureString returned from the SecurePassword property, nor does it access the security critical Password property. The SecurePassword value is simply forwarded to the command target of the registered CommandProperty attached property.
Fields
| Improve this Doc View SourceCommandProperty
Holds the ICommand which will be invoked with the SecurePassword of type SecureString as command parameter.
Declaration
public static readonly DependencyProperty CommandProperty
Field Value
| Type | Description |
|---|---|
| DependencyProperty | An ICommand implementation. |
Methods
| Improve this Doc View SourceGetCommand(DependencyObject)
The set method of the attached PasswordBox property.
Declaration
public static ICommand GetCommand(DependencyObject attachingElement)
Parameters
| Type | Name | Description |
|---|---|---|
| DependencyObject | attachingElement | The PasswordBox element. |
Returns
| Type | Description |
|---|---|
| ICommand | The ICommand implementation registered with the |
SetCommand(DependencyObject, ICommand)
The set method of the attached PasswordBox property.
Declaration
public static void SetCommand(DependencyObject attachingElement, ICommand value)
Parameters
| Type | Name | Description |
|---|---|---|
| DependencyObject | attachingElement | The PasswordBox element. |
| ICommand | value | An ICommand implementation. |