如题:
//前台代码
<PasswordBox x:Name="txtPwd" Height="" Width="" FontSize="" Margin="215,32,151,0" >
<PasswordBox.CommandBindings>
<CommandBinding Command="ApplicationCommands.Paste" Executed="CommandBinding_Executed" CanExecute="CommandBinding_CanExecute"/>
</PasswordBox.CommandBindings>
</PasswordBox>
//后台代码
private void CommandBinding_Executed(object sender, ExecutedRoutedEventArgs e)
{ } private void CommandBinding_CanExecute(object sender, CanExecuteRoutedEventArgs e)
{
e.Handled = true;
}