Ejemplo n.º 1
0
        public Window runOp(Window hWnd)
        {
            AutoItX3Lib.AutoItX3Class au3 = new AutoItX3Lib.AutoItX3Class();
            string name = settings["app_name"] + ":" + settings["app_instance"];

            au3.Opt("WinTitleMatchMode", 4);
            au3.WinActivate("[HANDLE:" + hWnd.handle + "]", "");
            au3.WinClose("[HANDLE:" + hWnd.handle + "]", "");
            hWnd.myProc.CloseMainWindow();
            Time.stopTimer(name, "runtime");
            return hWnd;
        }
Ejemplo n.º 2
0
        public Window runOp(Window hWnd)
        {
            AutoItX3Lib.AutoItX3Class au3 = new AutoItX3Lib.AutoItX3Class();

            au3.Opt("WinTitleMatchMode", 4);
            while (true)
            {
                au3.WinActivate("[HANDLE:" + hWnd.handle + "]", "");
                if (au3.WinActive("[HANDLE:" + hWnd.handle + "]", "").Equals(1)) { break; }
            }
            au3.WinClose("[HANDLE:" + hWnd.handle + "]", "");
            hWnd.myProc.CloseMainWindow();
            hWnd.myProc.Kill();
            Time.stopTimer("iTunes", "runtime");
            return hWnd;
        }
Ejemplo n.º 3
0
Archivo: Run.cs Proyecto: cquinlan/USBT
 public bool checkKeystroke()
 {
     AutoItX3Lib.AutoItX3Class au3 = new AutoItX3Lib.AutoItX3Class();
     au3.Send("^e", 0);
     while(true)
     {
         au3.WinActivate("All Displayed Items Chosen","");
         if (au3.WinActive("All Displayed Items Chosen", "").Equals(1))
         {
             au3.Send("{e up}{CTRLUP}", 0);
             au3.Send("{ESC 2}", 0);
             au3.WinClose("All Displayed Items Chosen", "");
             return true;
         }
     }
 }
Ejemplo n.º 4
0
        public Window runOp(Window hWnd)
        {
            AutoItX3Lib.AutoItX3Class au3 = new AutoItX3Lib.AutoItX3Class();

            string name = settings["app_name"];

            //au3.Opt("WinTitleMatchMode", 4);
            au3.WinActivate(hWnd.handle, "");
            au3.WinWaitActive(hWnd.handle, "", 5);
            au3.WinClose(hWnd.handle, "");
            au3.WinWaitClose(hWnd.handle, "", 5);
            if (!hWnd.myProc.HasExited)
            {
                hWnd.myProc.CloseMainWindow();
                hWnd.myProc.Kill();
            }
            Time.stopTimer(name, "runtime");
            return hWnd;
        }