Hello! Since there is no normal binding for PasswordBox, we had to do a binding through the command parameter for the button. As a result, the transfer from the view to the view model occurs through the method as follows:
Viewmodel
private void Auth(object parameter) { var passwordBox = parameter as PasswordBox; var password = passwordBox.Password; } public RelayCommand LoadedCommand { get { return loadedCommand ?? (loadedCommand = new RelayCommand(obj => { Auth(obj); })); } } View
<Button Command="{Binding AuthCommand}" CommandParameter="{Binding ElementName=passwordBox}"/> Now I need to transfer any password value to PasswordBox in the view from the view model, how can I do this?