Skip to content

Instantly share code, notes, and snippets.

@craibuc
Created January 8, 2015 16:10
Show Gist options
  • Save craibuc/41974122c555fdb07ee6 to your computer and use it in GitHub Desktop.
Save craibuc/41974122c555fdb07ee6 to your computer and use it in GitHub Desktop.
Export all Excel sheets (tabs) as individual HTML documents
set theSource to choose file with prompt "Choose file:" default location (path to desktop) of type {"XLS", "XLSX"}
set theDestination to (choose folder with prompt "Choose destination folder:" default location path to desktop)
set thePath to (theDestination as text) & "output.HTML"
tell application "Microsoft Excel"
activate
open theSource
tell active workbook
save as active sheet filename thePath file format HTML file format
end tell
quit saving no
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment