原地址:忘了
textBox1.KeyPress += anyTextBox_KeyPress; private void anyTextBox_KeyPress(object sender, System.Windows.Forms.KeyPressEventArgs e) { if (e.KeyChar == '\x1') { ((TextBox)sender).SelectAll(); e.Handled = true; } }
guxingy 2018-08-17 16:43 原文
原地址:忘了
textBox1.KeyPress += anyTextBox_KeyPress; private void anyTextBox_KeyPress(object sender, System.Windows.Forms.KeyPressEventArgs e) { if (e.KeyChar == '\x1') { ((TextBox)sender).SelectAll(); e.Handled = true; } }