How can I use Automator to open and save Word docs with links?
Hi-
I'm having trouble building a Workflow to open and save Word docs with links.
My Workflow so far:
1. Get Finder items
2. Copy Finder items (to new folder)
3. Rename selected items
4. Open selected items (Word docs)
Three problems occur.
The first is a Word 2004 problem -- I can't get the warning "This document has links in it; do you want to open it with/without updating the links" to go away (Unilke the Macro warning toggle capability, there is nothing in the Preferences for Word 2004 that addresses the links warning, as far as I can tell; any insight you can shed on this would be terrific.)
The second problem happens with Automator: if I manually accept the update of the first document's links, Automator opens that document but then halts completely, even though I've instructed it to open multiple documents.
The third problem I have is that there's no Finder action in Automator that allows me to save the document that's now open (as far as I can see).
Any suggestions for how to fix? If I can get this to work, and scheduled in iCal, it will be an unbelievable time saver.
Thanks,
Jeremy
PowerPC G5 Mac OS X (10.4.6)
Hi there Jeremy,
to do this you are going to have to add in some Run AppleScript steps...
These will rely on GUI Scripting. So first you need to activate GUI Scripting.
Now we need to add in a Run AppleScript action to the end of your workflow...
This will replace your current number 4 in the workflow (Open Selected...)
click here to open this script in your editor<pre style="font-family: 'Monaco', 'Courier New', Courier, monospace; overflow:auto; color: #222; background: #DDD; padding: 0.2em; font-size: 10px; width:400px">on run {input, parameters}
set allItems to every item of input
repeat with currItem in allItems
tell application "TextWrangler"
open currItem
end tell
activate application "TextWrangler"
tell application "System Events"
tell process "TextWrangler"
delay 2
--when the Word document is opened I have told it to press okay !
--I don't know what key you want it to press in the dialog box
keystroke return
delay 2
--save the doc
keystroke "s" using command down
delay 5
--close the doc
keystroke "w" using command down
end tell
end tell
end repeat
return input
end run</pre>
The above script should open each Word Document, press a button in the dialog box then do a save and then close the doc...then loop through the rest of them.
You need to replace the name Text Wrangler with Microsoft Word (or whatever it is called!), I don't have it on my Mac.
You will have to let me know what button needs pressing in the first dialog, if it isn't the 'highlighted ' one then we will have to amend the script...
regards
Ric
Similar Messages
-
How can i use my iPhone 4 and connect via bluetooth with my macpro
how can i use my iPhone 4 and connect via bluetooth with my macpro
The only way that you can connect your iPhone to the mac is to use it for a "Wi-fi hotspot" meaning that you can use the celluar connectivity of your phone to connect your computer to the interent.
Do you mean a MacBook Pro of the desktop MacPro? -
How can I use automator to open terminal change directory run a python script?
Hi all,
I dont really ever use automator - which may be my big problem - and I am trying to make an apllication that seems fairly simple in theroy. I want something that will lunch terminal, cd to the place where my python script lives and then run it. I have tried a number of suggested ways and can get the terminal to open and the directory to change but cant figure out how to run the script. This is my workflow if i did it manually each time
- open terminal
- type cd "the place where my file lives"
- type python uploadr.py -d
I can get terminal to open then cd to the right place but cant get the "python uploadr.py -d" to run without an error.
any help would be very appricated
thanks!!!
Jthis is the script I got closest with - I know its something to do with breaking those two commands up but i just dont know how to do it
on run {input, parameters}
tell application "Terminal"
activate
if (the (count of the window) = 0) or ¬
(the busy of window 1 = true) then
tell application "System Events"
keystroke "n" using command down
end tell
end if
do script "cd /Users/behole/Desktop/FlickrUpload/" & "python uploadr.py -d" in window 1
end tell
return input
end run
this is the error I get in terminal after I run it
Last login: Mon Jul 23 15:37:17 on ttys000
be-holes-MacBook-Pro:~ behole$ cd /Users/behole/Desktop/FlickrUpload/python uploadr.py -d
-bash: cd: /Users/behole/Desktop/FlickrUpload/python: No such file or directory
be-holes-MacBook-Pro:~ behole$ -
How can I use automator to copy and paste excel content to a new empty document?
Hi,
I would like to copy and paste the content from an excel file to another empty new document using automator, which I created a workflow like below
get specific finder item
open excel workbook
select cell from excel workbook (all content)
obtain selected content from workbook
copy to pasteboard the content of excel workbook
close the excel workbook
create new excel workbook
paste copyboard content to excel workbook
can anyone kindly suggest what's wrong with this workflow?
Thank you so much
Eddy
(i know this is a number place but I couldn't find any excel seciton sorry guys...)now it only does one file at a time, whereas I would like to do multiple files simultaneously.
If you try a search for "loop Automator" and also "folder actions" you may find some usable pointers on how to do that. The first example on this page looks promising.
SG -
How can I use Automator to extract specific Data from a text file?
I have several hundred text files that contain a bunch of information. I only need six values from each file and ideally I need them as columns in an excel file.
How can I use Automator to extract specific Data from the text files and either create a new text file or excel file with the info? I have looked all over but can't find a solution. If anyone could please help I would be eternally grateful!!! If there is another, better solution than automator, please let me know!
Example of File Contents:
Link Time =
DD/MMM/YYYY
Random
Text
161 179
bytes of CODE memory (+ 68 range fill )
16 789
bytes of DATA memory (+ 59 absolute )
1 875
bytes of XDATA memory (+ 1 855 absolute )
90 783
bytes of FARCODE memory
What I would like to have as a final file:
EXCEL COLUMN1
Column 2
Column3
Column4
Column5
Column6
MM/DD/YYYY
filename1
161179
16789
1875
90783
MM/DD/YYYY
filename2
xxxxxx
xxxxx
xxxx
xxxxx
MM/DD/YYYY
filename3
xxxxxx
xxxxx
xxxx
xxxxx
Is this possible? I can't imagine having to go through each and every file one by one. Please help!!!Hello
You may try the following AppleScript script. It will ask you to choose a root folder where to start searching for *.map files and then create a CSV file named "out.csv" on desktop which you may import to Excel.
set f to (choose folder with prompt "Choose the root folder to start searching")'s POSIX path
if f ends with "/" then set f to f's text 1 thru -2
do shell script "/usr/bin/perl -CSDA -w <<'EOF' - " & f's quoted form & " > ~/Desktop/out.csv
use strict;
use open IN => ':crlf';
chdir $ARGV[0] or die qq($!);
local $/ = qq(\\0);
my @ff = map {chomp; $_} qx(find . -type f -iname '*.map' -print0);
local $/ = qq(\\n);
# CSV spec
# - record separator is CRLF
# - field separator is comma
# - every field is quoted
# - text encoding is UTF-8
local $\\ = qq(\\015\\012); # CRLF
local $, = qq(,); # COMMA
# print column header row
my @dd = ('column 1', 'column 2', 'column 3', 'column 4', 'column 5', 'column 6');
print map { s/\"/\"\"/og; qq(\").$_.qq(\"); } @dd;
# print data row per each file
while (@ff) {
my $f = shift @ff; # file path
if ( ! open(IN, '<', $f) ) {
warn qq(Failed to open $f: $!);
next;
$f =~ s%^.*/%%og; # file name
@dd = ('', $f, '', '', '', '');
while (<IN>) {
chomp;
$dd[0] = \"$2/$1/$3\" if m%Link Time\\s+=\\s+([0-9]{2})/([0-9]{2})/([0-9]{4})%o;
($dd[2] = $1) =~ s/ //g if m/([0-9 ]+)\\s+bytes of CODE\\s/o;
($dd[3] = $1) =~ s/ //g if m/([0-9 ]+)\\s+bytes of DATA\\s/o;
($dd[4] = $1) =~ s/ //g if m/([0-9 ]+)\\s+bytes of XDATA\\s/o;
($dd[5] = $1) =~ s/ //g if m/([0-9 ]+)\\s+bytes of FARCODE\\s/o;
last unless grep { /^$/ } @dd;
close IN;
print map { s/\"/\"\"/og; qq(\").$_.qq(\"); } @dd;
EOF
Hope this may help,
H -
How can I use both, Windows PC and iMac, when using WiFi?. It is either-or. What can I do?
What does this have to do with using an iPad?
But yes, you should be able to connect to your home WiFi network with multiple computers and devices. In my house my wife, my daughter and I will all be using the WiFi Internet connection at the same time with our Laptops and I will also be using my iPad, my daughter uses her iPhone, and we have no issues at all.
Is this what you want to know about? -
How can i use Nikon D 7100 and Panasonic Lumix DMC-LF1 with Photoshop CS 5 Camera Raw?
How can i use Nikon D 7100 and Panasonic Lumix DMC-LF1 with Photoshop CS 5 Camera Raw?
The one needs 7.4 (or better), the other 8.1, so Photoshop CS5 with ACR6 is not up to the task.
The free DNG Converter could be used to convert the RAW images to DNG which your version of ACR should be able to process. -
How can a use a itunes soft. and create a new id
how can a use a itunes soft. and create a new id itunes ?
and
we are update the lattest version in my iphone 3gs 16gb ?
how can backup my iphone and install other application ?
pls. reply me .
jayesh panchalIt is not possible to delete an apple id completely. You can only delete information like credit card, adress, name... To do this, go to iTunes Store, click on your email adress in the upper right corner and enter your password. Now you can manage your account.
An apple id without password is not possible. -
How can i use Itunes to update more than one IPad with more than one owner
How can i use Itunes to update more than one IPad with more than one owner? I own an IPad and my wife owns an IPad. I want to use my system to update both IPads. We have different Apple Accounts and different applications. Is this possible?
Of course, that is too easy. I am such a bonehead.
-
How can I delete my apple id and create another one with the same email?
How can I delete my apple id and create another one with the same email?
So sorry; somehow I forgot to provide the link. Here it is ...
Frequently asked questions about Apple ID
Again, my apologies. -
How can I use automator to import a .csv file into a an excel file
I would still like all the import settings that I get if I am using excel to do the process, i.e. going in with the text format instead of the general format. That way my dates don't change
You'll need to use Applescript in Automator.
Note: File extension cannot be CSV (Excel will assume that the file is comma separated), so add an action to copy or rename with extension TXT.
(You can rename back at end of Workflow is needed)
The Applescript Action is:
on run {input, parameters}
repeat with f in input
tell application "Microsoft Excel"
open text file filename (f as string) data type delimited field info {{1, text format}} other char "|" with use other
end tell
end repeat
eturn input
end run
NOTE: This is formating the 1st col to text
If you need to format the second, then you need to:
open text file filename (f as string) data type delimited field info {{1, general format}, {2, text format}} other char "|" with use other
(You'll need to list the 1st col, 2nd col, etc until you get to the col to format as text). Formats are (from the Applescript Excel Library):
[field info list] : A list contain parse information for the individual columns of data.
Formats are general format, text format, MDY format, DMY format, YMD format, MYD format, DYM format, YDM format, skip column.
Or you can skip using Automator and just use an Applescript App (this is a droplet, just drop the files on the icon, or click to choose files):
on run
set fs to choose file with prompt "Select one or more files to open:" default location alias (the path to desktop folder as text) with multiple selections allowed
proceed(fs)
end run
on open fs
proceed(fs)
end open
on proceed(fs)
repeat with f in fs
tell application "Microsoft Excel"
open text file filename (f as string) data type delimited field info {{1, text format}} other char "|" with use other
end tell
end repeat
end proceed -
How can I use Automator to search only in folders whose name contains a certain word?
I'm very new to Automator. What I am trying to accomplish is this:
I am using Transmit as my FTP client. I have mounted a server as a disk to my desktop. I am using Automator to try and search this server and open files whose path contains the word "mobile", then open files with the name "order.php" with my HTML editor. There are hundreds other files on this server that have the name "order.php", so I just want to target the ones found in paths with the name "mobile" applied.
Where I get stuck is the "search only in paths that contain the word 'mobile' ".
Please advise.
Thanks.I'm very new to Automator. What I am trying to accomplish is this:
I am using Transmit as my FTP client. I have mounted a server as a disk to my desktop. I am using Automator to try and search this server and open files whose path contains the word "mobile", then open files with the name "order.php" with my HTML editor. There are hundreds other files on this server that have the name "order.php", so I just want to target the ones found in paths with the name "mobile" applied.
Where I get stuck is the "search only in paths that contain the word 'mobile' ".
Please advise.
Thanks. -
How to add My Documents to Open and Save as
Hi,
How can I add My Documents to the list of places under File ->"Open" and "Save as" in Office 2013 applications?
Users in my organization are truly frustrated by having to click on "Computer" and then choosing the "My Documents" folder every time they need to access their My Documents. Any suggestions?
Thanks!
-sul.Can you make a screen capture, or diagram showing exactly what you want to do? I just can't picture it.
If what you want to do is place it directly under the Open command in the File menu it would not be easy. The only slight possibility I can think of would be to create custom ribbon XML code to modify the "Backstage Pane". I
How do I change Backstage(File) view in Excel 2010
Customize the Office User Interface in Office 2010
http://technet.microsoft.com/en-us/library/ff468686.aspx
Updated: September 9, 2010
This article lists resources that will help you customize the Microsoft Office Fluent user interface (UI) in Microsoft Office 2010 applications.
Microsoft introduced the ribbon extensibility model in the 2007 Microsoft Office system as part of the Office Fluent UI. This was a new way to customize the user interface and create custom tabs and groups that
were specific to users’ needs. Office 2010 extends the span of the UI extensibility platform by providing support for customization of the new Microsoft Office Backstage view.
Customize the Backstage view
In Office 2010, the Microsoft Office button is replaced by the
File tab. The File tab brings you to the Backstage view. The Backstage view is customizable and lets organizations customize the UI to suit their needs.
For information about how to use and customize the Backstage view, see the following resources:
Introduction to the Office 2010 Backstage View for Developers (http://go.microsoft.com/fwlink/?LinkId=182189
http://msdn.microsoft.com/en-us/library/ee691833%28v=office.14%29.aspx
Customizing the Office 2010 Backstage View for Developers (http://go.microsoft.com/fwlink/?LinkId=184245
Change the Ribbon in Excel 2007 or Excel 2010
http://www.rondebruin.nl/ribbon.htm
Ron de Bruin (last updated 6-Oct-2010
<snip >
More RibbonX examples
You can download 8 Excel files here with basic RibbonX examples for Excel 2007 and Excel 2010.
Download Example Excel files Last Updated : 27-June-2010
Add custom group in built-in tab.xlsm
Add menu and buttons to Backstage or Office Button.xlsm
</snip>
I haven't seen any documentation about customizing the 2013 backstage. -
How can I use a bad IMEI AT&T iphone 5 with straight talk ?
Someone sold me a bad IMEI AT&T iphone 5. I had an AT&T iphone 4 with straight talk prior to buying this phone. I didn't know the IMEI was bad so I bought the iphone 5 hoping to switch. I cut my SIM card and put it into the iphone 5. Everything worked perfectly fine so I went ahead and gave the dude the money. I went to sleep and wake up the next day and try to make a call and I get a message saying my phone has been blocked from the network. I contacted straight talk and they thought it was a problem of theirs so somehow they got my phone to work again. Everything was good , calls, texts , and data. 2 hours later, the same problem happens. So I call straight talk again , tell them the problem. They fix It again, 2 hours later , THE SAME PROBLEM. I gave up this time and began looking for answers. Is there any way I can use this iphone 5 with straight talk ? There was a comment I saw through my search for answers where if I get another straight talk sim everything would work again. Is this true? How can I use a bad IMEI AT&T iphone 5 with straight talk ?
If that IMEI has been blacklisted by AT&T, then it is blacklisted by all USA carriers, as well as several participating Canadian and Mexican carriers.
As of 31 October 2012, USA Cellular Providers are sharing a common IMEI/ESN database to ensure that phones blacklisted on one carrier can't be activated on another carrier. AT&T and T-Mobile are also participating members of the GSM-networks global shared blacklists. -
How can i use index in select query.. facing problem with the select query.
Hi Friends,
I am facing a serious problem in one of the select query. It is taking a lot of time to fetch data in Production Scenario.
Here is the query:
SELECT * APPENDING CORRESPONDING FIELDS OF TABLE tbl_summary
FROM ztftelat LEFT JOIN ztfzberep
ON ztfzberep~gjahr = st_input-gjahr
AND ztfzberep~poper = st_input-poper
AND ztfzberepcntr = ztftelatrprctr
WHERE rldnr = c_telstra_accounting
AND rrcty = c_actual
AND rvers = c_ver_001
AND rbukrs = st_input-bukrs
AND racct = st_input-saknr
AND ryear = st_input-gjahr
And rzzlstar in r_lstar
AND rpmax = c_max_period.
There are 5 indices present for Table ZTFTELAT.
Indices of ZTFTELAT:
Name Description
0 Primary key( RCLNT,RLDNR,RRCTY,RVERS,RYEAR,ROBJNR,SOBJNR,RTCUR,RUNIT,DRCRK,RPMAX)
005 Profit (RCLNT,RPRCTR)
1 Ledger, company code, account (RLDNR,RBUKRS, RACCT)
2 Ledger, company code, cost center (RLDNR, RBUKRS,RCNTR)
3 Account, cost center (RACCT,RCNTR)
4 RCLNT/RLDNR/RRCTY/RVERS/RYEAR/RZZAUFNR
Z01 Activity Type, Account (RZZLSTAR,RACCT)
Z02 RYEAR-RBUKRS- RZZZBER-RLDNR
Can anyone help me out why it is taking so much time and how we can reduce it ? and also tell me if I want to use index number 1 then how can I use?
Thanks in advance.Hi Shiva,
I am using two more select queries with the same manner ....
here are the other two select query :
***************1************************
SELECT * APPENDING CORRESPONDING FIELDS OF TABLE tbl_summary
FROM ztftelpt LEFT JOIN ztfzberep
ON ztfzberep~gjahr = st_input-gjahr
AND ztfzberep~poper = st_input-poper
AND ztfzberepcntr = ztftelptrprctr
WHERE rldnr = c_telstra_projects
AND rrcty = c_actual
AND rvers = c_ver_001
AND rbukrs = st_input-bukrs
AND racct = st_input-saknr
AND ryear = st_input-gjahr
and rzzlstar in r_lstar
AND rpmax = c_max_period.
and the second one is
*************************2************************
SELECT * APPENDING CORRESPONDING FIELDS OF TABLE tbl_summary
FROM ztftelnt LEFT JOIN ztfzberep
ON ztfzberep~gjahr = st_input-gjahr
AND ztfzberep~poper = st_input-poper
AND ztfzberepcntr = ztftelntrprctr
WHERE rldnr = c_telstra_networks
AND rrcty = c_actual
AND rvers = c_ver_001
AND rbukrs = st_input-bukrs
AND racct = st_input-saknr
AND ryear = st_input-gjahr
and rzzlstar in r_lstar
AND rpmax = c_max_period.
for both the above table program is taking very less time .... although both the table used in above queries have similar amount of data. And i can not remove the APPENDING CORRESPONDING. because i have to append the data after fetching from the tables. if i will not use it will delete all the data fetched earlier.
Thanks on advanced......
Sourabh
Maybe you are looking for
-
This problem makes it impossible for me to sync any apple device to my itunes library. I have tried reinstalling itunes, but it still doesn't work. My computer recognises the devices, but itunes doesn't. Suggestions?
-
Steps to migrate SQL Database to Windows/Oracle
hi We have an SQL database in our client network and client wants to migrate it to Windows/Oracle. Currently they have multiple databases on the same SQL server. So I am curious to know if oracle also allows the same in Windows. I read that we can in
-
My iPod is not reconized by itunes or my computer help?
Yesterday my ipod was not reconized by my computer, so i restarted it and it worked fine. But today it wont work, i changed cords and i restarted my computer! it just wont connect. Any ideas??
-
Hi Experts, WIll any one pleasee xplain what is accounts payable / What is the full life cycle of accounts payable.Would be thankful if u cud explain me the flow BR, KK
-
Dear ALL After successfully shifting the CRM from 2011 to 2013 i found a problem in Reporting section none of the report is working after some finding i conclude that MSCRM_FetchDataSource is not able to connect successfully Through my report manag