Jump to content

keashdoc

Members
  • Posts

    10
  • Joined

  • Last visited

Everything posted by keashdoc

  1. Hi, I am trying to write an Autoit Code that will find a window with a specific caption and delete the process associated with that window. However, I am unable to find any code that does this. I tried this but it doesn't do the job. Any other ideas how I can accomplish this? Thanks. Global Const $partialCaption = "PartialCaption" ; Change this to the partial caption of the window you want to find While 1 If WinExists($partialCaption) Then Local $hWnd = WinGetHandle($partialCaption) If $hWnd <> 0 Then ProcessClose(WinGetProcess($hWnd)) ; Add a Sleep to avoid rapidly closing processes Sleep(1000) EndIf EndIf Sleep(1000) WEnd
  2. Hi, I have multiple Auto-it scripts that have about 20 lines of code in the beginning that is the same. Is there any way to save this common code into a separate file and then somehow import the common code into the individual Auto-It scripts? Thanks K
  3. That didn't work unfortunately. Its a special Citrix window so you may be right that it is not responding to normal maximize commands. However, if I click on the title bar, it does show a maximize menu option. I'll try getting the window position and choosing the dropdown menu to maximize it.
  4. Let me try the WinMove approach. That sounds like a good idea. Thank you so much for this info.
  5. You are awesome. Thank you so much Nine. That worked perfectly!!!!
  6. Hi, I want to launch a .m4a audio file using the default Media Player. I want the Media Player to run minimized / hidden and not be displayed. I only want to hear the audio without the Media Player being displayed. I tried this but Windows Media Player still pops up in the foreground. ShellExecute("c:\myaudio.m4a", "", "", "", @SW_MINIMIZE) Any suggestions would be greatly appreciated Kris
  7. Hi, I am trying to send a CTRL B command to enable bold typing to an electronic medical record program. When I type something in the EMR and click the left CTRL button and B simultaneously, the subsequent test is bold which is what I want. However, when I use an Autoit Script that does not happen. I have tried Send ("^B") and also Send ('{CTRLDOWN}B{CTRLUP}') and neither of them produce the desired result. I was wondering if anyone had any other suggestions. Why would the CTRL B command work when I type manually but not work with Autoit which I understand is simulating the keystrokes similar to typing? Thanks
  8. Hi, I am trying to automate Adobe Acrobat 9 Standard (running on Windows 7 home) to digitally sign documents. I have created the following script. ; ShellExecute("c:\esign\tosign.pdf") if winwaitactive("tosign","",30) then Winsetstate("tosign","",@SW_MAXIMIZE) sleep(300) ;MouseClick("left", 100, 100, 2) WinSetOnTop("tosign", "", 1) sendkeepactive("tosign") send("^0") sleep(300) send("^+{END}") sleep(300) ;send("!") ;sleep(500) ;send("D") ;mouseclick("left",460,60) ;send("!D") ;sleep(100) send("{ALT}+A") sleep(400) send("S") sleep(400) send("P") sleep(1000) ; WinSetOnTop("tosign", "", 1) ;mouseclickdrag("left",650,1100,1100,1130) sleep(500) ; sleep(200) ; send("{ENTER}") ; sleep(1000) ; send("c:\esign\signed.pdf") ; send("{ENTER}") ; sleep(1000) ;winclose("tosign") ;winclose("tosign") Else msgbox(0,"no","no") endif --------------------------------------------------------------------------------------------------------- When I run it, it opens the adobe, drops down the menu for signing and when the sign document dialog box comes up, it has lost focus and none of the commands are sent to that box. I have tried all sorts of trick - WinsetonTop, WaitWinActive and even clicking the mouse in the dialog box to get it to the forefront focus but nothing works. Does anyone have any idea how I can get the dialog box to stay at top and not loose focus? Thanks KEashdoc
  9. I tried something as simple as this and it doesn't move the mouse at all. Keashdoc ; AutoIt Version: 3.0 ; Language: English ; Platform: Win9x/NT ; Author: Jonathan Bennett (jon@hiddensoft.com) ; mousemove(1,1)
  10. Hi, I have a script that I was using for quite a while and today the mouseclick() feature stopped working. All the other functions work but the mouseclick() doesn't move the cursor or click on the specified coordinates. Windows updates were recently installed so I am wondering if that has anything to do with it. I reinstalled Autoit but have had no luck. Can anyone think of why suddently this function wouldn't work? Thanks Keashdoc
×
×
  • Create New...