AppleScript is a proprietary programming language in Mac OS X to control and exchange data with applications.

learn more… | top users | synonyms (2)

0
votes
2answers
30 views

AppleScript prints out keypresses, doesn't execute them

I expect this script to switch applications (command tab): $ cat hello.applescript tell application "System Events" key code 48 using command down end tell But it just prints out a tab: $ ...
1
vote
0answers
19 views

Is there a way to use automator/write an apple script to change the font in several powerpoint documents?

A recurring issue at work: A powerpoint file needs to be moved in to illustrator and saved as an .eps file. The files are almost always submitted with the font set to Calibri which Illustrator ...
1
vote
0answers
18 views

Creating an Automator/Applescript to compare two versions of an MS Word document

I'm storing MS Word documents in GIT and would like to have an rudimentary document compare system on the rare occasion that I need to diff them. I've seen: ...
0
votes
1answer
22 views

Applescript automate double keystroke

I need to emulate a keystroke using applescript for double time shift press. Adding Part of snippet.. tell application "System Events" keystroke shift keystroke shift end tell Even tried ...
1
vote
1answer
25 views

AppleScript keystroke ignoring numbers

A very simple AppleScript like this: tell application "System Events" keystroke "abc 123" end tell results in just “abc” being typed. Online resources suggest this should not be the case. ...
0
votes
1answer
34 views

Run an applescript on mouse down

How can I trigger an applescript on mousedown? I want this applescript to run when a user doubleclicks on empty space in the desktop (i.e. not clicking on the icons present on desktop). This is my ...
2
votes
1answer
33 views

Run an AppleScript that requires keystrokes while the screen is locked?

I've got a very simple AppleScript whose job it is to type some words into a text box. tell application "TextEdit" activate end tell delay 0.2 tell application "System Events" keystroke "Hello ...
1
vote
1answer
38 views

Difference between variable and pipe to shell in applescript

In answering this question I wrote this script: global presenterNotes tell application "Keynote" activate open (choose file) tell front document set presenterNotes to presenter ...
0
votes
2answers
20 views

Create an automator/applescript service that opens a file in an external program

Just wondering about some automator/applescript help. Basically: I download a MP3 file from an artist (for example) It is saved to my Downloads folder. From there, I want to open it automatically ...
1
vote
1answer
17 views

Get the Sound Output Device Name with AppleScript

How can I get the current sound output device name with AppleScript? For example, in my System Preferences: Sound pane "Internal Speakers" is currently selected. All I need to do is retrieve that ...
1
vote
1answer
44 views

Apps Stuck in Security & Privacy > Accessibility

I was messing around with using AppleScript for GUI manipulation so the apps I was making had to be granted access. The very first one I did showed up in Security & Privacy > Accessibility as ...
0
votes
1answer
18 views

Problem With the Click Command - AppleScript

I'm trying to do some GUI scripting with AppleScript but every time I try to use the click command, it will work but cause an error. If I use a try statement it works fine, but I shouldn't have to do ...
1
vote
0answers
27 views

Can I use AppleScript to upload a file to a webpage open in Safari using drag and drop?

I would like to create an AppleScript to open a specified URL in Safari, login automatically if that would be possible and then upload a file to a form that accepts drag and drop file upload. Would ...
0
votes
1answer
28 views

Applescript to change desktop image on all monitors?

I have the following code to change the desktop image of my Macbook tell application "System Events" tell current desktop set picture to "/Library/Desktop Pictures/Beach.jpg" end tell end tell How ...
1
vote
2answers
54 views

Open an new Safari window on the current space from the Termial shell with multiple tabs (URLs)

How to open an new Safari window from the Termial shell on the current space? Now when using the open http://example.com it got opened the URL as last TAB on my 1st safari window. I'm looking for ...
0
votes
1answer
16 views

Automator Service that works with and without selection

I have an AppleScript that I want to run with a keyboard shortcut. The script uses the current selection of text if it is available, but will also work without it. I have created an Automator Service ...
4
votes
1answer
38 views

How can I restart from an Apple script without warnings?

I wrote this Apple Script to bless my Windows partition and boot to Windows only once: do shell script "/usr/sbin/bless --device /dev/disk0s3 --setBoot --legacy --nextonly " with administrator ...
0
votes
1answer
66 views

AppleScript Error

Edit: Well now it seems to just work. I have no idea what's going on lol. Can someone tell me what's going on here? tell application "Terminal" do script "killall Finder" tell application ...
0
votes
2answers
72 views

In Applescript, how do I launch Safari “Silently” open url then close the unseen Safari window

I am new to Applescript and MACs although my first computer was an Apple II Plus and I programed in Apple Basic and Assembly. I am using it to create a "Silent" alarm button. We have a system in ...
0
votes
1answer
34 views

Grab the “Active” Window in Applescript

I have a script which perform the following: Load a file into a program (Subler — done separately, not in this script) Confirm the loading of the file (this is where the script begins) Saves the ...
0
votes
2answers
23 views

Geeklet script to ping hosts

I have found the nice script below to ping a host to check if it is up or down. However I haven't found a way (and my very basic programming knowledge has failed me here) on how I can ping multiple ...
0
votes
1answer
44 views

Using AppleScript to toggle Internet Sharing not working

I am using an applescript to activate internet sharing option from 'System Pref> Sharing'. I work on MacOs 10.9.4. I found this script on a forum and am using it. This works fine, when the System ...
1
vote
1answer
41 views

Applescripts not working in Finder since Mavericks

I have a bunch of Applescripts that do things like change sort column in Finder windows, but they've stopped working since Mavericks. If I close and reopen the window, then the change takes effect, ...
4
votes
2answers
73 views

Applescript File vs Alias

I have these two Applescript commands in which they both point to the same file alias "Macintosh HD:Users:scott:Dropbox:Downloads:AppleScriptFinderGuide.pdf" file "Macintosh ...
0
votes
1answer
30 views

How to fix my Applescript plugins for the Contacts application that are no longer available since 10.9 Mavericks upgrade?

I have got 5 scripts listed in ~/Library/Address Book Plug-Ins/ SkypeABDialer.bundle SkypeABSMS.bundle TelephoneAddressBookPhonePlugIn.bundle TelephoneAddressBookSIPAddressPlugIn.bundle Dial with ...
0
votes
2answers
33 views

I want to show a file in an AppleScript bundle, but shell returns: file not found

My Bundle File: reference.txt My Code: set bashFile to path to resource "reference.txt" set the reference_data to do shell script "type " & quoted form of (POSIX path of bashFile) display ...
0
votes
1answer
28 views

Where does Applescript Event Log go when run under Launchd?

Or, how to log from an AppleScript (saved as application) and/or view the Event Log? None of the AppleScript's log statements can be found. I have tried adding the following to the launchd plist: ...
0
votes
1answer
62 views

Converting Automator Action in applescript to bash script

I just wrote an Automator app using AppleScript (along with a couple of bash lines) to start FTP with a single click. However it runs more than a tad slow. Here's the code: set ftpstatus to "off" try ...
0
votes
0answers
33 views

Applescript and Outlook - can't get all occurrences of repeating events

I'm trying to export a list of all the events in my Outlook Calendar into a text file using the following code: set eventDetails to "" set currentDate to current date set yearFromNow to currentDate + ...
2
votes
1answer
22 views

What is the location of this Application's file?

This application shows in Finder at path (with target): Macintosh HD/Applications/Trans_Helper.app/Contents/MacOS/applet and I have not been able to successfully start it with launchd, using ...
3
votes
2answers
54 views

How to run Say “something” in background in AppleScript

I would like to have AppleScript code like this: row 1 say "some long text here" row 3 When it starts to speak text, it same time continues to row 3. I create my scripts in AppleScript Editor and ...
0
votes
2answers
29 views

Set Alias for Terminal Window in Applescript

After opening multiple terminal windows and running commands in them, it becomes difficult to send another command to a specific terminal window. How can we set an alias for each terminal window so ...
1
vote
2answers
13 views

How to make certain keystoke in AppleScript?

I am trying to make a program that records a live stream for a certain amount of time and then saves it on my desktop. This is what I have so far. TWiT Live Recorder (30 sec version) tell ...
0
votes
0answers
30 views

Keynote export with AppleScript broken in 6.2

I have recently upgraded both osx (to 10.9.4) and Keynote (to 6.2) and found this script, used to export Keynote presentation to HTML, no longer working. The script is simple: #!/usr/bin/osascript on ...
0
votes
1answer
39 views

Applescript System Events Keystroke broken after 10.9.4

It seems like the recent Mavericks update has broken the keystroke command in applescript -- whenever my script reaches that point, it freezes. (I currently have ~20 zombie osascript processes...) ...
0
votes
1answer
25 views

Creating a script that will execute a program and if it exits without crashing, will run it again

I've already asked this question in the UNIx exchange but I was told to ask here also about AppleScripts if the standard shell does not work. I require a script that will open an application. Wait ...
0
votes
1answer
36 views

How to download images from an xml feed using terminal?

How can I download png images from an xml feed that looks the following way? <ListBucketResult xmlns="http://url1.com"> <Name>imagesToUse</Name> <Prefix/> <Marker/> ...
0
votes
0answers
33 views

Automator sequential renaming for one file at a time

I have found many tutorials on how to rename some files using a "batch-renaming" type of workflow, but I have a different issue. I'm moving files one at a time into a folder, not all at once, so the ...
0
votes
1answer
32 views

Applescript Command as Specified User to Delete All Files in a Particular Folder

I am looking at using the POSIX path to delete the contents of a particular folder on users computers but it must be performed as a particular user. I can deploy the script silently from my side ...
1
vote
1answer
29 views

How do I create a scheduled task that deletes files of a certain name everyday?

Our voicemail system sends our messages to us via email as mp3 files. When I download the file, it comes down as "message.mp3", but of course OSX will rename them "Message (x).mp3" when you have more ...
0
votes
1answer
48 views

How to locate UI Button for AppleScript using Accessibility Inspector

There are several articles here that address this question, but none offer the help to connect-the-dots. The attached screen shot shot shows Accessibility Inspector for the button in question, which ...
0
votes
0answers
22 views

Tile Terminal Windows using Applescript

How can we use Applescript to tile multiple Terminal windows in the screen? Like in a arrangement of 3 cols by 2 rows. The following code simply overlaps all 6 windows. tell application "Terminal" ...
1
vote
1answer
70 views

How to Identify Safari Javascript Alert Dialog using AppleScript?

In a particularly 'pesky' website, a dialog box pops up to block (or cover) automated entry of the userid input box. I have used the following code attempting to get a reference & to close this ...
0
votes
0answers
21 views

AppleScript - Auto Press Keys

Using the AppleScript editor, I want pressing the "6" key in Google Chrome to also press the keys "1", "2", "3", "4", and "5". What's the easiest way to do this? I expect that there are some similar ...
0
votes
1answer
44 views

Banning domains temporarily from local access

I need to control myself. So far, I was using a Windows device for work, where I would simply reroute Facebook, news sites and similar to 127.0.0.1. In near future, I will have to use the same device ...
2
votes
1answer
40 views

Exponential Slowdown of Applescript

So I've been working on a simple AppleScript to try to help with managing my e-mail in OS X's Mail, and I have it seemingly working just fine with one major problem; the performance of the script is ...
2
votes
1answer
30 views

How to automate changing the settings when you connect the mouse?

I want to change option in System Preferences "Scroll direction: natural" every time I plugin mouse to my MacBook. And switch back when mouse is disconnected. This should happen automatically. How ...
1
vote
1answer
112 views

Automated Deletion of Messages From OS X Mail

Okay, so I know this is a tricky issue as OS X's Mail seemingly lacks the ability to automatically delete or archive old messages, even though it has the necessary date-based rules to do so. As such, ...
0
votes
0answers
29 views

Apple script in Error - “Microsoft Outlook gon an error:An error has occure.”

i try to export all mail from outlook using applescript but nested folder not export and display error: Apple script in Error - "Microsoft Outlook gon an error:An error has occure." number -2700 ...
0
votes
0answers
10 views

Word extension and AppleScript on Mavericks

I'm writing a scientific article and I would like to use the IUCr templates and tools, available via this program. Once installed, the program should let you select the journal you want to address and ...