Print from a Macro

204 views
Skip to first unread message

William Swan

unread,
Aug 17, 2019, 4:31:57 PM8/17/19
to Google Apps Script Community
In Google Sheets, i have recorded a macro to print multiple worksheets. It appears to work, as the printer prints the data as recorded. However, only the worksheets, that I moved to, are recorded in Scripts Editor.
I come to Sheets from MS Excel, and using VBA, I can record a print macro that works in a few minutes.

Their are 5 worksheets that I want to print in the attached file:
TOURN. SIGN IN SHEET
TOURN. DATA SHEET
SCORE CARDS
SCORE SHEET
WKLY HANDICAP

How do I print these worksheets from a Google Sheets macro?

Copy of JULY GOLF WORKBOOK 2019 (1).gsheet

Jonathan Butler

unread,
Aug 22, 2019, 9:31:08 PM8/22/19
to google-apps-sc...@googlegroups.com
By print, do you mean to have your printer physically print out those sheets? If so, I know HP supports eprinting. With that service, you can send an email to a printer with the document as an attachment and it will print the attachment. You can then use the MailApp to attach the document and send it to the printer.

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-script-community/3bedf09f-9ed2-4c60-97b3-405ce19a075f%40googlegroups.com.

Riël Notermans

unread,
Aug 23, 2019, 2:18:34 AM8/23/19
to Google Apps Script Community
You can also generate a PDF and use the Google Cloud Print API with Google Apps Script to send a print job.

Riël Notermans

Op woensdagen vrij • Zzapps B.V. • High Tech Campus 9, 5656 AE Eindhoven • T 040 711 41 94 • E ri...@zzapps.nl • www.zzapps.nl
WIJ MAKEN HET ONDENKBARE MOGELIJK


William Swan

unread,
Aug 23, 2019, 11:56:49 AM8/23/19
to google-apps-sc...@googlegroups.com
Riel, Thank you for your reply. I have decided to change to MS Excel.  That way, I know for sure that I can print using their macro language VBA.  I am disappointed that it seems Google Sheets does not support that capability at this time.   Bill Swan


Reply all
Reply to author
Forward
0 new messages