Talk About Network

Google




Programming > Applescript > Excel script to...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 3 Topic 1501 of 1697
Post > Topic >>

Excel script to save as CSV

by DonMega <scout7id@[EMAIL PROTECTED] > Aug 30, 2007 at 08:39 PM

I have been pounding my head over this one for a couple of weeks. I've 
been playing with it a few minutes a day. I am simply trying to drop an 
..xls file on my script and have it save the dropped script in the same 
directory as the original as a .csv file. Sounds simple right? Well 
this script works the first time around, sort of. It will do exactly 
that, except the resulting .csv file is empty. If I run it again, it 
tells me that 'active workbook' doesn't understand the 'save' command. 
I don't understand… Can someone help?

Here is the script:

on open fileList
	repeat with aFile in fileList
		set aFile to (aFile)
		tell application "Microsoft Excel"
			open aFile
			save ActiveWorkbook in (aFile & ".csv") as CSV
		end tell
	end repeat
end open


Thanks in advance.
 




 3 Posts in Topic:
Excel script to save as CSV
DonMega <scout7id@[EMA  2007-08-30 20:39:09 
Re: Excel script to save as CSV
Jolly Roger <wbyylebtr  2007-08-30 21:13:52 
Re: Excel script to save as CSV
Donald Fuller <donfull  2007-08-30 21:39:25 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
localhost-V2008-12-19 Tue Jan 6 5:31:06 PST 2009.