 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
david.kingham
Joined: 06 Nov 2007 Posts: 24
|
Posted: Mon Nov 02, 2009 9:30 pm Post subject: Continuous WinClose |
|
|
I'm having trouble making the IfWinExist/WinClose work continuously, it hits the return and sticks because there is no subroutine to return to, probably really stupid and simple but how do I get around this? Thanks!
| Code: | #SingleInstance force
#NoTrayIcon
SetTitleMatchMode RegEx
Hotkey IfWinActive, Autodesk| Revit Architecture|Structure|MEP 2008|2009|2010 .*
Hotkey ^f, SEARCH
Hotkey ^F1, WTF
Hotkey ^k, KeynoteManager
IfWinExist Visual Studio Tools for Application Disabled
WinClose
IfWinExist Journal Error
WinClose
IfWinExist Copied Central File
WinClose
IfWinExist Linked File Cannot Be Saved
WinClose
Return
SEARCH:
Run Find Q:\Revit\Content\Neenan Library
Return
WTF:
IfNotExist %A_MyDocuments%\Revit Launcher\Revit_Architecture_UI_Mapping_Tool.chm
FileCopy \\nevada\drawings\Revit\Files\2010\Architecture\Revit_Architecture_UI_Mapping_Tool.chm, %A_MyDocuments%\Revit Launcher, 1
Run %A_MyDocuments%\Revit Launcher\Revit_Architecture_UI_Mapping_Tool.chm
Return
KeynoteManager:
FileCopy \\nevada\drawings\revit\install\other\Keynote manager\keynote manager.exe, %A_MyDocuments%\Revit Launcher, 1
FileCopy \\nevada\drawings\revit\install\other\Keynote manager\masters.txt, %APPDATA%\Keynote Manager, 1
Run %A_MyDocuments%\Revit Launcher\Keynote Manager.exe
Return |
|
|
| Back to top |
|
 |
Leef_me
Joined: 08 Apr 2009 Posts: 5336 Location: San Diego, California
|
Posted: Mon Nov 02, 2009 11:15 pm Post subject: |
|
|
| Quote: | | it hits the return and sticks because there is no subroutine to return to | No, the script executes the return, and that part of the script is done.
see here: http://www.autohotkey.com/docs/Scripts.htm#auto
A timer could be used to repeat the desired instructions at some interval.
(untested) I suggest, after this line in your script
| Code: | | Hotkey ^k, KeynoteManager |
Insert these lines
| Code: | settimer, kill_windows, 1000 ; 1000ms = 1 second.
return
kill_windows:
|
|
|
| Back to top |
|
 |
david.kingham
Joined: 06 Nov 2007 Posts: 24
|
Posted: Tue Nov 03, 2009 8:33 pm Post subject: |
|
|
| Thank you, that worked perfectly. |
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|