27 lines
883 B
VB.net
27 lines
883 B
VB.net
Public Class OnlyProdInputPwdWndV
|
|
|
|
Private WithEvents m_InputPwdWndVM As InputPwdWndVM
|
|
|
|
Sub New(Owner As Window, InputPwdWndVM As InputPwdWndVM)
|
|
MyBase.New(Owner)
|
|
' This call is required by the designer.
|
|
InitializeComponent()
|
|
PwdBox.Focus()
|
|
Me.DataContext = InputPwdWndVM
|
|
' Assegno al riferimento locale al VM il VM preso dal DataContext
|
|
m_InputPwdWndVM = InputPwdWndVM
|
|
End Sub
|
|
|
|
' Sub necessaria per ottenere la stringa immessa nella PasswordBox
|
|
Private Sub PasswordBox_PasswordChanged(sender As Object, e As RoutedEventArgs)
|
|
If Not IsNothing(Me.DataContext) Then
|
|
Me.DataContext.sPassword = DirectCast(sender, PasswordBox).Password
|
|
End If
|
|
End Sub
|
|
|
|
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_InputPwdWndVM.m_CloseWindow
|
|
Me.DialogResult = bDialogResult
|
|
End Sub
|
|
|
|
End Class
|