Hi,
I'm using these lines in my AHK script that's loaded when Windows starts up. It allows me to just click the tray icon with the left mouse button once to reload the script:
Code:
#Persistent ; Keep this script running until the user selects Exit.
Menu, Tray, Click, 1 ; Remove this line if you prefer double-click vs. single-click.
Menu, Tray, Add ; Separator
Menu, Tray, Add, &Reload, Reload
Menu, Tray, Default, &Reload ; what you define as default is bolded
return
Problem: sometimes it not only reloads the script but clicks 'through' the refreshed tray icon (that's moved to the last position in the tray) on the icon that replaces its old position, wich results in unwanted behaviour.
I heard there's a way to automatically reload the script whenever I save the file? Possible? CPU consuming? Any ideas?
Thanks!
_________________
DonationCoder.com brings AHK to the newbies!
Fan of AutoHotkey? Consider an occasional
donation to its developer, Chris Mallett.