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

learn more… | top users | synonyms (3)

1
vote
0answers
32 views

Adding Bounce Message back to Mail in Yosemite

Does anyone have an updated version of this workflow for adding a Bounce Message feature to Apple Mail in OSX 10.10.3? Applescript: on run {input, parameters} tell application "Mail" ...
1
vote
2answers
807 views

How do I collect all of my notes and highlights from iBooks?

I've got a lot of highlighting and notes in iBooks that I've read, and would like to be able to collect them in one easy to use and manipulate format (e.g for writing papers and citing quotes). For ...
0
votes
1answer
21 views

Applescript for multiple find/replace using separate masterlist

I am trying to create a script to extract a list of data from column A on document 1, and then use columns A & B on document 2 as multiple find/replace data. Everything works in so far as ...
4
votes
1answer
1k views

enabling/disabling Internet Sharing with terminal in mac osx 10.9.2

The problem is setting the internet sharing with CLI instead of GUI in Mac OS 10.9.2 I followed instructions as per this thread Start/stop internet sharing from a script? including both CLI and ...
13
votes
3answers
13k views

Run AppleScript from bash script

If I wanted to run an AppleScript from within a bash script I could call a file with the list of commands that I require to execute. #!/bin/bash {some commands} osascript file.scpt {other commands} ...
0
votes
0answers
14 views

Capture a sequence of clipboard copy contents into a file [closed]

I want automatically capture a sequence of clipboard copy contents into a file. Is this possible to do in AppleScript? If so, how to do it?
4
votes
3answers
156 views

Script to change downloaded mac wallpaper automatically?

I want to change my mac wallpaper daily with microsoft bing images. I found this script that download the daily picture automatically, but I sill have to set the wallpaper automatically. Is it ...
7
votes
4answers
2k views

look up a word in Dictionary.app in Terminal

Is there a bash or applescript to look up a word in /Applications/Dictionary.app from a Terminal window ? open -a /Applications/Dictionary.app/ --args word ignores --args, says "type a word to look ...
0
votes
1answer
1k views

copy calendar entries from one calendar to another via apple script throws error

i am trying to copy ical entries from one calendar to another using the following script: tell application "iCal" set localEvents to events of calendar "Privat" set remoteEvents to events of ...
1
vote
1answer
30 views

AppleScript Quicktime Player to play audio file generates error

My Quicktime Player (Version 10.3 727.4) can play mp3 files without any problems, but when I use AppleScript I get an error message: The document “audio.mp3” could not be opened. The file may be ...
1
vote
2answers
54 views

Applescript (PDF to iTunes): How to extract and/or write metadata with special characters? Help please :-)

INTRODUCTION Hello there, Like always, I want to put in front that I'm not a script expert. I'm not even a basic coder. I just try to learn, little by little about coding when I have these ...
0
votes
1answer
120 views

how to re-enable services in an app (Microsoft Remote Desktop in particular)

I am fairly confident I could use the service below in MRD before. I am not sure when I lost them, maybe it is related to the Yosemite upgrade (I noticed this on 10.10.0) or some recent MRD update ...
1
vote
1answer
26 views

How to make a custom keybind that runs an applescript file?

No additional questions. I'm fine with installing an additional program.
1
vote
3answers
2k views

Using automator and handbrake cli to convert videos automatically

I am trying to automate video conversion process using Automator and Handbrake CLI version. I am trying to implement the functionality that whenever a video is downloaded in my dropbox folder on my PC ...
0
votes
1answer
18 views

Filling the inputs of SecurityAgent if they exist?

I am trying to automate the export of my keychains (system and user), and while my script works if I remove the set values, it does not after adding them. The error I am receiving is System Events ...
0
votes
1answer
23 views

How to Change Scroll Speed Programmatically with Applescript or Shell Script

Is there a way, using either applescript or a shell script, to change the scroll speed? I don't even know where to begin to look for a mechanism for this. Oh, and no third-party applications either, ...
2
votes
1answer
31 views

Using Launchbar to make Popclip appear

PopClip is a Mac app that adds the iOS functionality of a bunch of options showing up above selected text. PopClip automatically appears every time I select text, and that's annoying, so I want to ...
0
votes
0answers
33 views

Setup and sync multiple Google Drives

I am trying to setup and sync multiple instances of Google Drive on OS X Mavericks. I have tried the two following instructions here, and here, but to no avail. Each time I try to run the new ...
0
votes
0answers
9 views

Automator Workflow - Reply To Outlook Messages with Template Text

I have pulled together the following workflow in Automator because my Scripting knowledge is non existent: Problem It pastes the text in unformatted, losing all paragraphs, bold, underlined, ...
6
votes
2answers
149 views

Why are Script Editor .scpt files not saved as plain text files?

The Script Editor (formerly ApplerScript Editor pre-Yosemite) saves .scpt files as binary files, not plain text files. It makes working with them in source code control systems somewhat cumbersome. ...
4
votes
1answer
66 views

What are the differences between Applescripts saved as *.scpt and *.applescript?

It seems to me that those scripts that are saved as *.applescript are always meant to be the raw, uncompiled text while those that are saved as *.scpt can be either the raw text or the compiled ...
1
vote
1answer
33 views

Get nick name of current user

I want to get the nickname of the currently logged in OS X user via Apple Script. Currently can only retrieve the full name or the nickname of a contact, I wasn't able to combine the two scripts. ...
0
votes
1answer
42 views

How can I use Applescript or any other utility to send a daily text message to my bank?

I have searched and I find a lot of results for specific methods of sending an iMessage with Applescript, but they all seem to contain extraneous code for specific needs that I don't need. I'm ...
0
votes
0answers
14 views

FFMPEG via AUTOMATOR not working argument “drawtext timecode”

I am new to scripts and automation but I wrote a script to help me on my daily job of watermarking and burn in timecode on videos. I created an Automator drop on app to convert videos and watermark ...
1
vote
2answers
56 views

Simple 3 line applescript - Error -128

I have a scenario where I'd like 2 separate applescripts. The idea is super simple. 2 Applications, but only one runs at a time. Example: Close application 1, launch application 2 (and vise versa) ...
0
votes
1answer
41 views

Using applescript to create spaces and launch apps

So the end goal of what I am looking to do is this: When I am at work I use an external monitor with my MBP. I have a consistent set of spaces and apps that I setup everyday. What I would like to ...
2
votes
2answers
36 views

if application “Safari” visible is false then (AppleScript)

I would like to check if Safari is visible, my AppleScript code was this, but it doesn't work ... How can I check the visible with AppleScript? if application "Safari" visible is false then tell ...
3
votes
1answer
161 views

How can I avoid permission-related failures when importing in Photos.app via AppleScript?

The new Photos.app does not come with Automator support (although there are third-party actions available). It does, however, have some basic AppleScript support, including support for importing a ...
1
vote
3answers
1k views

Applescript dictionary for Preview

Is there an Applescript dictionary for Preview.app? I am unable to find it under Mac OS X 10.7.5, and Applescript 2.2.1. I did a rudimentary search in google and duckduck but came up empty. I've ...
-2
votes
1answer
43 views

applescript to unlock mac works very slow

Hello i am using this script to unlock the mac tell me to activate\n tell application \"System Events\" to keystroke \"PASSWORD\"\n tell application \"System Events\" to keystroke return\n tell ...
1
vote
0answers
16 views

Tell last media player to skip song

I bought a new keyboard that, of course, works almost perfectly, minus the media buttons. Luckily it has open source drivers specifically for linux and mac, but unfortunately the media buttons ...
-1
votes
1answer
1k views

How to add a script that types in the password for my vps through applescript

I made a script recently and have turned it into an app, it basicly logs me into my vps via ssh but I don't know how to tell it how to type in my password for me, heres the code tell application ...
0
votes
0answers
14 views

How can I securely store passwords in xcode app?

I'm writing an app with Xcode using Applescript-ObjC. I'm wanting to put in some usernames and passwords to automatically check some remote servers. How can I put these login credentials in the app ...
1
vote
1answer
52 views

How to Use Cancel Button in Osascript to Stop Running Script

Here is my basic script: #!/bin/bash osascript -e 'tell application id "com.apple.systemevents"' -e 'display dialog "Do you want to continue?" & return & return & " Please wait..." ...
0
votes
2answers
43 views

How to check if invisible items are visible?

How do I check in AppleScript, if invisible objects are visible? If visible, do: defaults write com.apple.finder AppleShowAllFiles 0 in invisible, do: defaults write com.apple.finder AppleShowAllFiles ...
1
vote
0answers
22 views

How to detect if chrome (or any other app) is playing sound using bash/applescript

I am writing a script to turn off audio on my mac, but need to check if its coming from the browser or an app (say Spotify). Is there a way to detect which app is playing sound?
-1
votes
1answer
12 views

Using variables in pathnames and pathname variable help plus finding username applescript?

So, I want to have my script to be able to find out the current user's username and store it in a variable (myUsername). Then, it will go to /Users/myUsername/Desktop/FV.app. How can I do this and ...
1
vote
3answers
2k views

Using applescript to lock screen

I need an applescript which locks my Mac in the same way pressing "shift"+"ctrl"+"eject" would. I tried two different approaches, but both failed. The first one was to search the internet for a ...
0
votes
3answers
1k views

AppleScript for iCal events from Address Book entries

I want to create a script that creates alarmed events in iCal for birthdays of people that I have in my address book. Unfortunately, I am very bad working with AppleScript. Below is the outline of ...
0
votes
0answers
21 views

Applescript and iTunes: enable shuffle by song or album and play?

The documentation for shuffle/shufflable in the iTunes Applescript dictionary is really confusing, at least for me. As I read it shuffle seems to be a property of a playlist (not a state of the ...
-1
votes
2answers
78 views

AppleScript for restarting to Bootcamp?

I have tried to use an AppleScript to reboot to Windows It's not going well though, as when I tried it the first time, a white screen appeared on startup and didn't go away. A hard reset rebooted to ...
0
votes
1answer
35 views

Use AppleScript to play an iTunes Radio station vs. an iTunes Internet Radio station?

Looking for hints or a code snippet that will show me how to use AppleScript to play an iTunes Radio Station (with cover art, add to iTunes wish list, play more like) vs. playing an iTunes Internet ...
0
votes
1answer
31 views

Using Applescript to paste the current date into a range of Excel cells

I have a simple script written that successfully saves the current date in the format I need. I also have saved a destination range in the active sheet. I just need syntax to paste/insert it into that ...
1
vote
1answer
34 views

How to programmatically construct the name of application used to open directories?

This Emacs LISP script reveal-in-finder.el allows one to quickly open a directory in Finder from an Emacs buffer which has the directory opened in it in dired mode. But on my computer, I uses Path ...
2
votes
1answer
135 views

Applescript: Help to extract PDF “Author” metadata and set it in iTunes Author field

Using other applescript as template, I've been trying to modify this particular one to do the following task: Extract "Author" tag from a PDF file and write it automatically in the iTunes12 "Author" ...
0
votes
0answers
25 views

How do I a search with applescript cocoa that sets properties with actions

A little bit of context here, I have a text file which is compiled of all the computers and users of my network, its referenced so I can easily find and VNC into them. My regular applescript looks ...
2
votes
1answer
68 views

How to replace all Finder files with a placeholder file for each

I have lots of files from a database which are to be copied to a new database, but the files for these are corrupt (They are zero-byte in size and contain no data). Rather than the new database ...
0
votes
1answer
14 views

Launch Apple Script on App Focus

Is there a way to configure an Apple Script (or any script for that matter), to be run every time an application is focused? For example, if I am on Safari currently, and I tap on a QuickTime window, ...
2
votes
2answers
142 views

Make a file a Stationery pad via command line

Is there a way to set make a file into a Stationery pad from the command line? You can do it by clicking "Get info" on a file and checking the box, but I would like to do it without clicking. An ...
0
votes
0answers
21 views

AppleScript/Automator Add AutoCorrect Settings

I am making a AppleScript/automator script for April Fools that is going to change the AutoCorrect. I know that I can change the autocorrect settings by going to Settings > Text > '+' ...