applescript

How to automate extracting pages from a PDF using AppleScript and Acrobat Pro?

删除回忆录丶 提交于 2020-01-01 16:53:29
问题 I'm new to AppleScript, but I am trying to create a script that will go through all PDFs in a folder extracting the pages into separate files. My plan is to use a combination of Automator and AppleScript. My AppleScript so far is: tell application "Adobe Acrobat Pro" open theFile set numPages to (count active doc each page) --execute the extraction here end tell The command in Acrobat Pro is under Options > Extract Pages... , where I can specify the page range and to extract to separate files

Click menu item on Mac OSX Lion using AppleScript

一个人想着一个人 提交于 2020-01-01 12:14:18
问题 I have a problem using a simple AppleScript on Mac OSX 10.7.3. With the following simple AppleScript which I find everywhere OSX raises an error 'The action "Run AppleScript" encountered an error' I open up the Automator, create a Service, drop in a "Run AppleScript" node and enter the following code which I assume is correct because as I said it is the way a lot of people are doing it without any complaints. AppleScript: tell application "Terminal" to activate tell application "System Events

Click menu item on Mac OSX Lion using AppleScript

[亡魂溺海] 提交于 2020-01-01 12:14:09
问题 I have a problem using a simple AppleScript on Mac OSX 10.7.3. With the following simple AppleScript which I find everywhere OSX raises an error 'The action "Run AppleScript" encountered an error' I open up the Automator, create a Service, drop in a "Run AppleScript" node and enter the following code which I assume is correct because as I said it is the way a lot of people are doing it without any complaints. AppleScript: tell application "Terminal" to activate tell application "System Events

Click menu item on Mac OSX Lion using AppleScript

二次信任 提交于 2020-01-01 12:14:04
问题 I have a problem using a simple AppleScript on Mac OSX 10.7.3. With the following simple AppleScript which I find everywhere OSX raises an error 'The action "Run AppleScript" encountered an error' I open up the Automator, create a Service, drop in a "Run AppleScript" node and enter the following code which I assume is correct because as I said it is the way a lot of people are doing it without any complaints. AppleScript: tell application "Terminal" to activate tell application "System Events

run applescript on 2x-click

孤街醉人 提交于 2020-01-01 08:00:20
问题 OK, this feels like an idiot question, but I'm stuck - I don't know the first thing about AppleScript. I have a .scpt file and I want to double-click it and just have it run, but instead every time I click, it opens up the AppleScript Editor. This feels like it should just be an option on the file, but I'm missing something obvious. Please help me feel less dumb, thank you. 回答1: From the “File” menu, choose “Export”; there’ll be a “File Format” dropdown underneath the file browser. To get a

Make the screen Flash from Mac OS Terminal

浪尽此生 提交于 2020-01-01 07:23:35
问题 I using different build scripts for package my apps. Some of them running a while and it would be great to have a visual notification the script is ready. I already use the notifications center with an Apple Script but something it is not alarming enough. Is it possible to run and Applescript or a command line command to let the screen flashes. A plus would be to flash in different colors (green for OK and red for build failed). 回答1: I have a couple of ideas... Easiest: Go to Terminal-

In Applescript, how can I find out if a menu item is selected/focused?

时光总嘲笑我的痴心妄想 提交于 2020-01-01 05:29:10
问题 I have a script for OS X 10.5 that focuses the Search box in the Help menu of any application. I have it on a key combination and, much like Spotlight, I want it to toggle when I run the script. So, I want to detect if the search box is already focused for typing, and if so, type Esc instead of clicking the Help menu. Here is the script as it stands now: tell application "System Events" tell (first process whose frontmost is true) set helpMenuItem to menu bar item "Help" of menu bar 1 click

Is there a way to list all files and their targets in Xcode?

前提是你 提交于 2020-01-01 03:37:13
问题 I am part of a project with multiple developers. The project contains multiple targets. VERY often, files are committed to the Xcode project repository with some targets not-included (careless programmers). So whenever i do a 'svn up', and run the app, my program crashes. I then have to look through all those files and see which one was committed with the missing target, then add the target, and recommit the file to the repository (for that careless programmer) Is there some way through a

Alternatives to Applescript? [closed]

断了今生、忘了曾经 提交于 2020-01-01 02:41:29
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 6 years ago . When it comes to scripting the Mac, are there alternatives to Applescript? Its API seems awesome, but the language itself, from what I

Alternatives to Applescript? [closed]

纵然是瞬间 提交于 2020-01-01 02:41:19
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 6 years ago . When it comes to scripting the Mac, are there alternatives to Applescript? Its API seems awesome, but the language itself, from what I