The way to make Form indicate once again automatically after sendkeys execution

Hello
I am improving my application now.

To make Form indicate once again automatically after sendkeys execution, I am combining "visible", "activate" and "sleep" variously, but none works.
Aren't there any good ways?

//A part of program
this.Visible = false;
SendKeys.Send(command);

 if (action == "o")
   {//Open Form again
       System.Threading.Thread.Sleep(10000);//wait 10 sec
       this.Visible = true;
       this.Activate();
   }

Parents Reply
  • I am sorry for the delay in my response.
    It's because I suffered from making of 'Editor' unexpectedly.

    When using a short cut in most cases, the user finishes only by once operation.
    And users have to do several operations(several short cuts) in some operations.
    For example" Select Next Match (Alt + PgDn)" and" Apply Translation (Ctrl + T)".

    When 2 operations(short cut) are necessary, when using my current application, 4 operations are necessary.
    (1.displays my form. 2.button click. 3.displays my form. 4.button click.)
    I'd like to change this to 3 operations.
    (1.displays my form. 2.button click. 3.button click.)
Children
No Data