Unlock the Secrets of PDF Generation with Google Apps Script

แชร์
ฝัง
  • เผยแพร่เมื่อ 9 ส.ค. 2022
  • Create a PDF using Google Docs template, populate the template from sheets data and send out the PDF via mailApp.
    In this tutorial, we'll be exploring Google Apps Script and how it can be used to create PDFs. We'll be using the Google Sheets API to create and manage our PDFs, and show you how to create different types of PDFs using Google Apps Script.
    If you're new to Google Apps Script and want to learn how to use it to create PDFs, then this tutorial is for you! We'll walk you through the basics of Google Apps Script and show you how to create a simple PDF document using the Google Sheets API. By the end of this tutorial, you'll have a better understanding of Google Apps Script and be able to create PDFs using the Google Sheets API!
    Google Apps Script has proven itself a highly useful and highly valuable resource in the ecosystem of low-code/no-code. It’s been around long before the term “low-code” and consequently, evolved over the years, from new learnings and new opportunities within Google Workspace.
    Speaker: Laurence Svekis is a Google Developer Expert who is creating online courses with over 700,000 students - web development and technology-related content creators.
    #appscript #google #js #javascript #nocode #lowcode #googleappsscript #appsheet #googleworkspace #googledocs #automation
  • วิทยาศาสตร์และเทคโนโลยี

ความคิดเห็น • 39

  • @xxxChubyxxx
    @xxxChubyxxx ปีที่แล้ว +1

    A real Life Saver !!!!!!!! Thank you ! this saved me a ton of money and well I really appreciate it

  • @BurritoBrooks
    @BurritoBrooks 2 หลายเดือนก่อน +1

    That was awesome! Didn’t even know this was possible. Thanks!

  • @brightadewole6784
    @brightadewole6784 ปีที่แล้ว +2

    Highly resourceful. Many thanks for this

  • @xxxChubyxxx
    @xxxChubyxxx ปีที่แล้ว +1

    I already Commented but this video was so good thanks !!!!!!!!!!!!!! again

  • @RobKraut
    @RobKraut 6 หลายเดือนก่อน

    This was awesome! Thank you! One question: I have URLs to images on my google sheet as well. Is there a way to embed the image into the Google Doc template with this method?

  • @Trackdaygenius
    @Trackdaygenius 4 หลายเดือนก่อน

    This is a Life saver! One question, if I remove the email function will the if(row[0] == ‘’){ function still work, to check if the date column is empty? As i need the ability do select certain rows to generate the pdf, I have 120 rows, I don’t need all of them to be generated…

  • @ciceropontes7732
    @ciceropontes7732 ปีที่แล้ว

    Beautifully done! I'm working with some dates and times. When I get the dates or times, they come in the format like Sat Apr 29
    2023
    02:00:00
    GMT-0400
    (Eastern
    Daylight
    Time). How can I do in order to get (and show in the pdf generated) just 4/29/23 format for dates and 11:30 PM format for time? tks.

  • @brunoserman78
    @brunoserman78 10 หลายเดือนก่อน

    Great video, Lawrence, thank you very much! Would you be able to make a copy of the code available to us, please?

  • @gasparlam4267
    @gasparlam4267 ปีที่แล้ว +1

    Thank you so much!
    Is it possible to get the pdf opened right after it is created? or even get it printed by local printer?

    • @LaurenceSvekisCourses
      @LaurenceSvekisCourses ปีที่แล้ว

      Yes but not in the apps script, you need to run frontend code for this JavaScript can handle that.

    • @LaurenceSvekisCourses
      @LaurenceSvekisCourses ปีที่แล้ว

      You would need a web page to trigger the download or open to printer

  • @MunnaBhaiUSA
    @MunnaBhaiUSA ปีที่แล้ว +2

    Great Video! How do we speed up this script to complete this process way faster (if my google sheet had many rows)

    • @LaurenceSvekisCourses
      @LaurenceSvekisCourses ปีที่แล้ว

      You can mail out more canned messages, how many rows do you have?

  • @LightTheLampLLC
    @LightTheLampLLC ปีที่แล้ว +1

    Great Video!
    Quick Question, how do you take the value of the spreadsheet classified as dollars/currency/accounting and apply it to the word document to transfer over as same $ format? This video has been beneficial and got everything working except the formatting of the numbers.
    Example: In excel sheet $240,000.00 but generated in word document --> 240000 and transferred into the PDF same as the word.
    Do you have any suggestions on that?
    Thank you again for your time!

    • @LaurenceSvekisCourses
      @LaurenceSvekisCourses ปีที่แล้ว

      have you tried setting the type in Google sheets before export.

    • @scotttauriello250
      @scotttauriello250 ปีที่แล้ว

      @@LaurenceSvekisCourses Yes, I have tested all types in google sheets to see if it's impacted and it is not. The numbers do not generate over as same format as currency or finance. I have also tried to set the word template as well with the incorrect results. Any other suggestions? I have looked online and it seems no one has tried using $ numbers to transfer only whole numbers.

    • @ashfaqashraf7700
      @ashfaqashraf7700 8 หลายเดือนก่อน

      Try typing the replacers in doc this way ${price}

  • @derekdimmick8666
    @derekdimmick8666 7 หลายเดือนก่อน

    I have a sheet with a table already on it that is updated from info from other sheets all inside one sheet. Hopefully you follow. I want google sheets to automatically just make that one sheet a pdf and save it to my google drive. So probably half of what this script is doing. How can I accomplish that?

  • @mpsychservices1325
    @mpsychservices1325 11 หลายเดือนก่อน

    Hi can, you make a content that encrypts the pdf with a password. Thank you

  • @iprsa
    @iprsa ปีที่แล้ว +1

    Thank you very much. It it a realy great video and code. Is it posible, to replace an old pdf file with a new one in app script. I have link to pdf file in Google Drive, posted on internet, I just want to create a new pdf file and update the old one to remaine the same link.

    • @LaurenceSvekisCourses
      @LaurenceSvekisCourses ปีที่แล้ว

      You can create a new PDF with the same name, while deleting the old file if you need the same path.

  • @immi1498
    @immi1498 ปีที่แล้ว +1

    Link plz?

  • @BraveHeart-ht8zf
    @BraveHeart-ht8zf 7 หลายเดือนก่อน

    How if I want sent automation email contains pdf tables with different emails every 12 hours

  • @gegklungkung
    @gegklungkung 3 หลายเดือนก่อน

    where is the pdf file, i try your code. No found error but pdf not create on folder. please other tutorial create pdf only from sheet data.

  • @user-mu4ze2zh8y
    @user-mu4ze2zh8y ปีที่แล้ว +1

    I wish you would show the code fully to help us debug easily.

    • @mathewforsyth1006
      @mathewforsyth1006 ปีที่แล้ว +2

      I pasted my code above in a comment. It does not include the email function, but it will save you a bit of time, if you've not already typed it out ;)

  • @Nico_Aramy
    @Nico_Aramy ปีที่แล้ว +1

    is it possible if we sent the file to whatsapp ?

  • @danielpaes6457
    @danielpaes6457 ปีที่แล้ว

    how to preview a pdf file for the user to choose whether to print or save to the computer? I'm trying but without success!