i found this post: http://bbs.applescript.net/viewtopic.php?id=23033
i tried to edit it for myself without the pdf bit but it doesn’t seem to work. all i want to do is create a script for iCal to open with an alarm that prints off a single excel file, so i would want:
close excel — unless excel was open before the script ran (ie, i was using it already and don’t want it to quit any unsaved work)
if anyone can help i’d really appreciate it, cheers
set thefile to choose file
tell application "Microsoft Excel"
print out active sheet
close active workbook saving no
cheers for replying. it doesn’t seem to work for me, i get this message:
Microsoft Excel got an error: active sheet doesn’t understand the print out message.
not sure what the problem is. my printer is set to the default printer if that helps.
can you email me an example of the file you’re trying to print?
Just click the Email button on the left of my post.
i can’t actually, the email me link leads to a webform with no option to add attachments!
the file is a simple excel file, there are no special formattings or anything. it is all just text. there is some personal information in there, it should be ok if i clear the contents of the file and save it, and send it to you right? i’m not sure what you’re looking for with the example. it was created with excel for mac 2004, not a windows version.
if email me and then I can reply and you’ll get my email address.
If I have an example it just makes it easier to see where it’s going wrong, take out any personal details.