AppsScriptPulse

Creating your on preview ink Smart Chips in Google Docs: The Untold Potential of Apps Script

 

Alright, folks, we’re talking about something quite hot off the press in the realm of Google Apps Script — “Smart Chips.” This feature is available within Google Docs and can build previews of pasted links using the Card Service. Think of it as a little preview window of what lies beyond the link — a sneak peek, if you will. 🕵️‍♂️

Editor: Smart chips are a recent feature in Google Workspace that help you quickly insert information into your Docs and Sheets. They can be used to insert people, places, dates, and more. It’s also possible for Google Workspace developers to publish their on ‘Preview links’ smart chips as Workspace Add-ons. In this post from Dmitry Kostyuk you can learn about publishing your own smart chips and some creative ways to get the data you need using Google Apps Script.

Source: Previewing Links with Smart Chips: The Untold Potential of Apps Script

Easily merge data from Google Sheets into Google Docs and Slides with the TemplateApp Google Apps Script

This report introduces the method for easily processing the template of Google Documents and Google Slides using Google Spreadsheet as a database using Google Apps Script. Google Spreadsheet is used as a database. Google Documents and Google Slides are used as templates. The simple method for creating new Google Documents and Google Slides using the database and the templates is introduced.

Latest Apps Script magic from Kanshi Tanaike, this time they turn their addition to an easy way to use data from Google Sheets as a ‘document merge’ for templates created in Google Docs and Google Slides. This is achieved by using the TemplateApp Apps Script library, which has lots of useful features including simply methods for sheetRangeToDocuments() as well as the ability to embeded and fixed width images from placeholders. There are some llimitations documented in the GitHub repo, as well as examples for all the methods available in the library.

[In other ‘merge’ news Google have announced that you can now use Google Sheets with Google official mail merge in Gmail]

 

Source: Easily Processing Templates of Google Documents and Google Slides using Google Spreadsheet with Google Apps Script

Create instant summaries in Google Docs: A step-by-step guide with OpenAI API and Google Apps Script

In today’s fast-paced digital world, effectively condensing lengthy content has become a necessity. Whether you’re a student grappling with research papers or a professional striving to stay ahead, generating concise summaries can save time and boost productivity. Luckily, the powerful combination of OpenAI APIs and Google Apps Script provides a seamless solution for effortlessly summarising paragraphs within Google Docs

Learn how to generate instant summaries in Google Docs using a step-by-step guide that combines the OpenAI API and Google Apps in this informative blog post on Medium. Discover the power of automated summarisation to enhance your document creation process.

Source: Create Instant Summaries in Google Docs: A Step-by-Step Guide with OpenAI API and Google Apps Script

Automating Google Docs Creation from Google Spreadsheet using Google Apps Script

If you frequently find yourself creating multiple Google Docs that follow a similar template and pull data from a Google Spreadsheet, this tutorial is for you. Today, I’m going to show you how to automate the process using Google Apps Script.

I liked the simplicity of this script which does a very basic data merge on Google Docs template from Google Sheets data. There is a bit of piecing together to get this one working but basically it’s uses a very simple replaceText pattern which maps the spreadsheet column number to replacement tokens {{col1}}, {{col2}}, etc. Read the source post to see all the code.

Source: Automating Google Docs Creation from Google Spreadsheet using Google Apps Script

Create a Google Doc for a single row of Google Sheet data with Google Apps Script

Use a row of data in a Google Sheet to pass to a Google Doc via Apps Script

Use a row of data in a Google Sheet to pass to a Google Doc via Apps Script

Create a Google Doc containing the information from a selected row of Sheet data.

The following Google Apps Script is designed to create a Google Doc for the selected row of data in a Google Sheet and to include some of that data within the new Doc. it also creates a link to the new Doc back in the Sheet on the relevant row.

Source: The Gift of Script: Create a Google Doc for a single row of Sheet data

The Ultimate Google Apps Script Front-End Development Guide. Part 0: The Worst and the Best Practices

Welcome to the Ultimate Google Ultimate Google Apps Script Front-End Development Guide!

If you are reading this post, then you likely have experience with Google Apps Script. Essentially, there are three types of front-ends that you can create with Apps Script:

  • Web apps
  • Modal/modeless dialogues
  • Sidebars

In this blog post series, we will only discuss HTML front-ends, as this is where you can create the most powerful and sophisticated user experiences. Unfortunately, the Card Service is outside the scope of this series, and it is not nearly as powerful as an HTML front-end. With that in mind, Google, how about allowing HTML front-ends for Workspace add-ons?

Source: The Ultimate Google Apps Script Front-End Development Guide. Part 0: The Worst and the Best Practices

Check external links in Google Docs with Google Apps Script widget

Image credit: Mykyta Khmel

Google Docs is a popular document editor for creating and editing text documents, spreadsheets, and presentations. With the use of Google Apps Script, a scripting language for automating tasks in Google Apps, users can enhance their document editing experience by adding custom functionality to Google Docs. One such functionality is the ability to check URLs within a Google Document.

Nice little project that has some useful code snippets/functionality you might find useful in your own projects which extracts and tests hyperlinks included in a Google Doc. The post provides an outline of how the script is setup and lets the user interact via a sidebar. I always find interacting with Google Docs a little daunting, particular parsing the document structure. The post links to a useful gist by Mogsdad (David Bingham) with some basic Google Document utility scripts.

Source: Check link statuses in Google Docs with Apps Script widget

Quick backup solution for Google Apps Script by creating versions in Google Docs

Get security and peace of mind by backing up your Google Apps Script files to Google Docs and trigger for continuous backup.

We’ve featured a couple of methods for restoring Google Apps Script code in Pulse, but most of these rely on recovering a deployed version of the script. Stéphane Giron wields his Apps Script hammer and skilfully demonstrates how you can use Google Docs and it’s built-in version history as a way of keeping a backup copy of your code.

Source: Quick and not so Dirty backup solution for Google Apps Script Code

Using OCR to convert large images to Google Docs with Google Apps Script (avoiding Request Too Large error)

When the image size, the image file size, the resolution of the image, and so on are large, an error like Request Too Large occurs. In this sample script, such the image can be converted to Google Document by reducing them.

Here is a workaround for converting large images to Google Docs from Kanshi Tanaike. The post includes a code snippet and link to related Stack Overflow Q&A. As noted in the SO discussion the solution might be a compromise for some developers as it reduces the image resolution being passed into Google Drive and if you need to keep the original quality you might have to look at other paid services.

Source: Converting Large images to Google Document by OCR using Google Apps Script

BAS#005 | Create a Google Slides presentation handout in Google Docs with Apps Script

Generate summary documents of your Google Presentations with thumbnails and speaker notes using Apps Script. In this BAS you will learn how to generate a summary text document with the thumbnails and notes obtained from the slides from a Google presentation. For this we will use the Apps Script services of Documents (mainly) and Presentations. Plus, you’ll do it efficiently thanks to the awesome UrlFetchApp.fetchAll() method.

If you don’t speak/read Spanish you’ll have to hit Google Translate to read this latest contribution from Pablo Felip. As described by Pablo: “Apps Script Basics (Básicos Apps Script – BAS, in Spanish) is a series of posts targeted to newcomers to Google Apps Script. Each BAS solves a simple, real-world problem, provides a thorough step-by-step break-down of the source code suitable for people who are learning how to leverage this platform and introduces key Apps Script patterns.”. This particular ‘Básicos Apps Script’ includes some useful information on building tables in Google Docs which could be useful in other contexts like generating reports.

Source: BAS#005 | Generating a presentation summary document with Apps Script