![]() ![]() Despite my undying protestations against using Finder for anything AppleScript related except telling it to quit, I actually elected to use it for this task because it can enumerate a folder structure recursively with entire contents ( if one knows how to use it optimally-I wrote a post about this a while ago outlining the principles of this), and because it allows one to enumerate scriptable applications that need not be running processes: every application file class object in Finder has the has scripting terminology property too. I made a library a while ago that dealt with this sort of thing, so I dug out a couple of handlers from it and checked it still works (in High Sierra). Tell application "Script Editor" to activate Tell application "System Events" to tell process "Script Editor" to perform action "AXRaise" of window selectedApp Tell application "Script Editor" to activate # duplicate activate commands are intentional Set appFile to path to application appNameĭisplay dialog appName & " does not have a dictionary." buttons # option to resize dictionary window Set appDictionary to has scripting terminology of appProcess Set appProcess to first application process whose frontmost is true ![]() This does have a practical consequence during normal use in that FastScripts is not responsive during the 5-second period. I wondered if anyone knew how to prevent my script from running as described in 3 above. This brings the Script Editor dictionary to the front but Script Editor continues to show “running” for about 5 seconds. Without closing the dictionary, activate Script Editor and run the script again. Run the script, which loads the Script Editor dictionary. ![]() To replicate:Ĭopy and paste the script contained below into Script Editor. My script works fine and I’ll use it a lot, but I did encounter one small issue. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |