Excel 2004, AppleScript and CSV import

M

Mark Asbach

Hi Office-Users,

I've got problems with AppleScript and Excel 2004 on Mac OS 10.3. What
I've been trying to is to import CSV data. I can do that manually with
the Import Assistant in the GUI, but if I use the corresponding
AppleScript command ('open text file'), it looks like, none of the
parameters (regarding delimiter setting) are really honoured.

Is there some demo on how to use it? The old syntax from Office v.X
does'n work any longer.

Yours, Mark
 
P

Paul Berkowitz

I've got problems with AppleScript and Excel 2004 on Mac OS 10.3. What
I've been trying to is to import CSV data. I can do that manually with
the Import Assistant in the GUI, but if I use the corresponding
AppleScript command ('open text file'), it looks like, none of the
parameters (regarding delimiter setting) are really honoured.

Is there some demo on how to use it? The old syntax from Office v.X
does'n work any longer.

It works fine here:

tell application "Microsoft Excel"
open text file filename "PB G5 HD
Tiger:Users:berkowit:Documents:Script Bugs:Contacts Export EvX.csv" with
comma
end tell

( 'comma true' compiles to 'with comma' as booleans always do.)


If the CSV came from Windows then you'd need to add ' origin MSWindows'.

There's a very substantial Excel 2004 AppleScript Reference (462 pages), as
well as References for Word and PowerPoint, at the MacTopia website -->
Resources --> Developer --> AppleScript.

--
Paul Berkowitz
MVP MacOffice
Entourage FAQ Page: <http://www.entourage.mvps.org/faq/index.html>
AppleScripts for Entourage: <http://macscripter.net/scriptbuilders/>

Please "Reply To Newsgroup" to reply to this message. Emails will be
ignored.

PLEASE always state which version of Microsoft Office you are using -
**2004**, X or 2001. It's often impossible to answer your questions
otherwise.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top