title: Save Clean CSV file from Excel using Applescript
body: <p>I have a process that requires downloading an Excel Spreadsheet from the Web, opening it using Excel Mac 2008, saving it as a csv file, and then parsing it using php. The manual process works fine and saves a clean CSV file. I am trying to automate this part using Applescript, and it sort of works, however, the CSV file generated contains a bunch of weird characters.</p>
  
  <p>Here is the Applescript I am working on:</p>
  
  <pre><code>tell application id "com.microsoft.Excel" to open "~/Documents/input.xls"
  tell application id "com.microsoft.Excel" to tell active sheet to save in ("output.csv") as "CSV file format"
  </code></pre>
  
  <p>I have tried various CSV options (Mac, Windows, MSDos) and they do not produce substantially different results.</p>