onButtonClick(){
button.Enabled = false;
//I have tried this to keep the TextBox from gaining focus, but it will still be highlighted/selected
form.Focus();
try
{
perform tests and IO operations here
}
catch
{
deal with exceptions
}
finally
{
button.Enabled = true;
button.Focus();
}
}
onButtonClick(){
button.Enabled = false;
//I have tried this to keep the TextBox from gaining focus, but it will still be highlighted/selected
form.Focus();
try
{
perform tests and IO operations here
}
catch
{
deal with exceptions
}
finally
{
button.Enabled = true;
button.Focus();
}
}