• Complain

Mcpherson - Going GAS: from VBA to Google Apps Script

Here you can read online Mcpherson - Going GAS: from VBA to Google Apps Script full text of the book (entire story) in english for free. Download pdf and epub, get meaning, cover and reviews about this ebook. City: Sebastopol;CA, year: 2016, publisher: OReilly Media, genre: Home and family. Description of the work, (preface) as well as reviews are available. Best literature library LitArk.com created for fans of good reading and offers a wide selection of genres:

Romance novel Science fiction Adventure Detective Science History Home and family Prose Art Politics Computer Non-fiction Religion Business Children Humor

Choose a favorite category and find really read worthwhile books. Enjoy immersion in the world of imagination, feel the emotions of the characters or learn something new for yourself, make an fascinating discovery.

Mcpherson Going GAS: from VBA to Google Apps Script
  • Book:
    Going GAS: from VBA to Google Apps Script
  • Author:
  • Publisher:
    OReilly Media
  • Genre:
  • Year:
    2016
  • City:
    Sebastopol;CA
  • Rating:
    5 / 5
  • Favourites:
    Add to favourites
  • Your mark:
    • 100
    • 1
    • 2
    • 3
    • 4
    • 5

Going GAS: from VBA to Google Apps Script: summary, description and annotation

We offer to read an annotation, description, summary or preface (depends on what the author of the book "Going GAS: from VBA to Google Apps Script" wrote himself). If you haven't found the necessary information about the book — write in the comments, we will try to find it.

Note continued: VBA FileSystemObject -- Apps Script DriveApp Service -- 10.HTML Service -- Why Client Execution? -- The Downside -- The VBA Connection -- HTML Service Varieties -- Web Apps -- Dialogs -- Sidebars -- jQuery -- Event Handling -- Templates -- Structure -- Controlling Apps Script from the Client -- Using Namespaces in HtmlService -- Multiple Menu Items -- indexRun.html -- mainRun.js -- Client Namespace -- Render.js -- App.js -- Dialog HtmlService -- HtmlService Web Apps -- VBA User Form -- Create a User Form -- Initialize the Combo Box -- Listen for Changes -- The Form -- 11.Content Service -- The Content Service -- Where to Use the Content Service -- Types of Content -- Example -- Request -- Response -- Details -- doGet -- The Settings -- SheetOb -- getFlight -- getRegex -- Initial Result -- JSONP -- XML -- makeXml -- Publishing -- Script Files -- The Publishing Process -- Permissions -- Delegation from VBA -- Querying Apps Script -- 12.Charts;Note continued: Copy/Paste Port -- Native Port -- Arguments to Custom Formulas -- Performance -- Documentation and Autocomplete -- Adding Functions to Menus -- Tables -- Converting Values to an Object -- Emulating Tables in Apps Script -- ListObject -- 7.The Document App -- Opening Documents -- Working with Elements -- Traversing the Document -- Traversing in VBA -- Annotating the Document -- Ranges -- VBA Range -- VBA Discontiguous Ranges -- RangeElements -- The showRange Utility -- RangeBuilder -- Named Ranges -- Setting a Cursor Using a Named Range -- Position -- Position Within Element -- Creating a Selection -- Creating a VBA Selection -- Inserting Text -- Bookmarks -- IDs -- VBA Bookmark Insert -- Bookmark Appearance -- Traversing Bookmarks -- Text Bookmarks -- Creating Links -- Setting a Cursor Position -- Removing Bookmarks -- Editing Text in Elements -- Adding Elements -- Containers -- Element childIndex -- VBA childIndex -- Inserting Elements -- Tables;Note continued: OneDrive Authentication -- Other OAuth 2.0 Services -- OAuth 2.0 with VBA -- Developers Console -- getGoogled -- Content Service with OAuth2 -- Other Kinds of Authentication -- Basic Authentication -- JWT (JSON Web Tokens) -- What Is a JWT? -- Firebase Authentication -- JWT Format -- FirebaseAuth Namespace -- Standardized OAuth 2.0 Process -- 16.External APIs and Integration -- REST API -- Code -- Reuse -- Databases -- Firebase -- Main Code -- Permissions -- Settings -- Firebase Class -- Reuse -- Result -- Databases and Apps Script -- 17.Execution API -- What Is Incremental Migration? -- Migration Process -- The Execution API -- Inventory for Execution API -- Authentication and Access -- Credentials -- Publishing -- Scopes -- Getting Googled -- JSON -- SheetExec -- Example Workflow Migration from Office -- Moving a Workbook to Sheets -- VBA Code to Read a Sheet -- Apps Script Code to Read a Sheet -- VBA Code to Write Data to a Local Workbook;Machine generated contents note: 1.Introduction -- What Is VBA? -- Extending -- Fragility -- Security -- Asynchronicity -- Efficiency and Performance -- Maintainability -- What Is JavaScript? -- A Quick History -- Versions -- JavaScript Is Not Java -- Learning JavaScript -- What Is Apps Script? -- Versions -- It Runs on a Server -- Services -- Fully Authenticated Environment -- Quotas -- Performance -- Asynchronicity -- Events -- Triggers -- Web Apps -- Maintainability -- IDE -- What Is Apps Script Good For? -- What Are Google Add-Ons? -- Types of Add-Ons -- Security -- The Publishing Process -- What Are Google Forms? -- What Are Microsoft Add-Ins? -- Comparison -- 2.Language Basics -- Style -- Hungarian -- Camel Case -- Case Sensitivity -- Copy/Paste Porting -- Types -- Operators -- Mathematical Operators -- Assignment Operators -- String Operators -- Comparison Operators -- Logical Operators -- Bitwise Operators -- Variables -- Variable Types -- Functions;Note continued: Chart Data -- VBA Charts -- Code -- Sheets Charts -- EmbeddedChartBuilder -- setPosition -- Types of Chart -- Visualization API -- Google Visualization HtmlService App -- Other Chart Formats -- 13.Sites -- Apps Script -- Gadgets -- Code Lockdown -- Advertising -- VBA -- The Future of Sites -- 14.Advanced Google Services -- What Are Advanced Google Services? -- Advanced Services Versus Google APIs -- Developers Console -- Enabling Advanced Services -- Fusion Tables Example -- Settings Namespace -- Copy Sheet to Fusion -- Fusion Namespace -- Fusion Quotas -- Scripts Structure -- Currently Available Advanced Services -- 15.Authentication and Security -- OAuth 2.0 -- Setup -- Access -- Refresh -- Scopes -- Limiting Scope to the Current Document -- Listing Authorized Apps -- Revoking Access -- ScriptApp -- Service Accounts -- Libraries -- OAuth 2.0 Example -- Creating the Cloud Console Project -- Scopes -- Accessing Other Oauth 2.0 Services;Note continued: Container-Bound Versus Standalone Scripts -- Getting Started with the Spreadsheet Service -- A Note About Authorization -- Opening the Active Sheet -- The Range Class -- Creating a Range -- Returning the Data Range -- Getting the Values of a Range -- Writing Values to a Range -- Returning Selected Data -- Reading and Writing for Partial Ranges -- Reading Attributes from a Range -- Writing Attributes to a Range -- Inserting and Deleting Rows and Columns -- Opening Other Sheets -- Iterating All Sheets -- Getting a Sheet by Name or Index -- Opening Other Workbooks -- Creating a Standalone Script -- Accessing Multiple Workbooks -- Working with Multiple Workbooks -- Updating Sheets -- Showing Messages -- Toast -- Showing Messages with Buttons -- Getting Input -- Getting and Setting Properties -- Document, User, or Script? -- Setting Properties in the Registry -- Setting Properties Using the Properties Service -- Changing Settings -- Custom Formulas;Note continued: Helper Functions -- String Functions -- Conversion Functions -- Math Functions -- Informational Functions and Constants -- Date and Time Functions -- Optional Arguments -- Testing for undefined -- Applying Default Values -- Named Arguments -- Handling Errors -- VBA Exception Branching -- JavaScript try/catch -- Raising an Error -- VBA Built-In Objects -- Type -- Key/Value Pairs -- Collections -- 4.Living with the Quotas -- The Quotas -- Daily Limits -- Limitations -- Triggers -- Rate Limits -- Throttling -- Sleeping -- Exponential Backoff -- Splitting -- Libraries -- Batching -- Parallel Running -- Offloading -- Avoiding Service Calls -- Cache Service -- 5.The Properties Service -- APIs Versus Built-In Services -- Getting Started with Properties Service -- Uses and Types of Property Stores -- Selecting a Property Store -- The Registry Versus the Property Store -- Comparisons -- 6.The Spreadsheet Service -- Custom Formulas;Note continued: List Items -- VBA ListParagraph -- Images -- Docs Automation Example -- Selecting the Target Area -- Inserting the Table -- Adding to Custom Menu -- Attributes -- Text Attributes -- Attribute Equivalence -- Partial Attributes -- Attribute Indices -- 8.Gmail, Calendar, and Contacts Apps -- Email Automation Exercise -- Scenario -- Threads -- Searching -- Messages -- Message Filtering -- Regular Expression Searching -- Name Lookup -- Body Errors -- Result Reduction -- Generate a Regular Expression -- Attachments -- Organizing -- Recipients -- Organizing by Recipient -- Sending -- Labels -- VBA Categories -- Calendar -- Events -- The Courses Namespace -- Advanced Calendar Service -- Contacts -- ContactGroups -- Contacts Namespace -- Organizing Courses -- Setting Up the Example -- The Settings -- Triggers -- Apps Script Main Function -- VBA Main Function -- Scheduling -- 9.Drive and DriveApp -- Microsoft OneDrive -- Reading and Writing Files;Note continued: VBA Code to Write to a Sheet from a Local Workbook -- Apps Script Code to Write to a Sheet from a Local Workbook -- Migrating Logic -- VBA Code to Initiate Logic on Apps Script -- Logic Code Delegated to Apps Script -- VBA Orchestration -- VBA Process Orchestration Code -- Apps Script Logging Code -- Final Migration Steps -- Testing JavaScript on the PC -- VBA Code to Get Source Code from Apps Script -- Apps Script Code to Return Source Code -- Getting the Source and Testing Local Execution -- Execution API Potential -- 18.Office Add-Ins and Google Add-Ons -- Add-Ons -- Add-Ins -- The Same... -- ... But Different -- Add-On Example -- The Dataset -- Capabilities -- Apps Script Add-On -- What You Will Learn -- The Namespaces -- Sharing Code Between Client and Server -- index.html -- main.js -- styles.css -- App Namespace -- Cors -- Add-On Script -- Reused Namespaces -- Server Namespace -- Client Namespace -- Render Namespace -- Testing an Add-On;Note continued: Office Add-In -- What You Will Learn -- The IDE -- Structure -- index.html -- mainOffice.js -- App.js -- Client.js -- Testing the Add-In -- Result Comparison -- Further Exercises.;Note continued: Assigning Functions to Variables -- Anonymous Functions -- Functional Programming -- Loops and Iteration -- Layout -- Whitespace and Newlines -- Semicolons -- Curly Braces -- Scope -- Objects -- JavaScript Object Notation -- JSON Examples -- Classes -- Prototypes and Constructors -- Inheritance -- Methods -- A Note on this -- Getters and Setters -- VBA Example -- Using Object.create -- Conclusion -- Namespaces -- Google Services -- Libraries -- Creating Your Own Namespace -- Avoiding Namespace Collisions -- The IDE -- Container-Bound Scripts -- Standalone Scripts -- Code Examples -- Accessing the IDE -- Running a Function -- Examining Results -- Libraries -- Libraries in the Cloud -- Namespaces and Libraries -- Managing Library Versions -- Adding Libraries to a Project -- Some Notes on Library Sprawl -- 3.Translating VBA Functions -- Conventions -- Library and Namespace -- JSDOC -- JSDOC Example -- VBA Built-Ins Translated to JavaScript

Mcpherson: author's other books


Who wrote Going GAS: from VBA to Google Apps Script? Find out the surname, the name of the author of the book and a list of all author's works by series.

Going GAS: from VBA to Google Apps Script — read online for free the complete book (whole text) full work

Below is the text of the book, divided by pages. System saving the place of the last page read, allows you to conveniently read the book "Going GAS: from VBA to Google Apps Script" online for free, without having to search again every time where you left off. Put a bookmark, and you can go to the page where you finished reading at any time.

Light

Font size:

Reset

Interval:

Bookmark:

Make
Going GAS

by Bruce Mcpherson

Copyright 2016 Pepada limited. All rights reserved.

Printed in the United States of America.

Published by OReilly Media, Inc. , 1005 Gravenstein Highway North, Sebastopol, CA 95472.

OReilly books may be purchased for educational, business, or sales promotional use. Online editions are also available for most titles (http://safaribooksonline.com). For more information, contact our corporate/institutional sales department: 800-998-9938 or corporate@oreilly.com .

  • Editor: Meg Foley
  • Production Editor: Colleen Lobner
  • Copyeditor: Rachel Monaghan
  • Proofreader: Jasmine Kwityn
  • Indexer: Judith McConville
  • Interior Designer: David Futato
  • Cover Designer: Randy Comer
  • Illustrator: Rebecca Demarest
  • February 2016: First Edition
Revision History for the First Edition
  • 2016-02-08: First Release

See http://oreilly.com/catalog/errata.csp?isbn=9781491940464 for release details.

The OReilly logo is a registered trademark of OReilly Media, Inc. Going GAS, the cover image of a spotted thick-knee, and related trade dress are trademarks of OReilly Media, Inc.

While the publisher and the author have used good faith efforts to ensure that the information and instructions contained in this work are accurate, the publisher and the author disclaim all responsibility for errors or omissions, including without limitation responsibility for damages resulting from the use of or reliance on this work. Use of the information and instructions contained in this work is at your own risk. If any code samples or other technology this work contains or describes is subject to open source licenses or the intellectual property rights of others, it is your responsibility to ensure that your use thereof complies with such licenses and/or rights.

978-1-491-94046-4

[LSI]

Preface
Why Read This Book?

Perhaps you already use VBA to extend Office, but are considering alternatives. You may have already gone Google, or you might be looking at Microsofts Apps for Office options. In particular, youre wondering what to do with all the VBA code built up over the years that you consider essential to enabling your business processes.

This book will show you how to transition from VBA with minimal effort. Even if you are not a VBA user, you will learn how to use Apps Script and its ecosystem to automate processes in the Google Apps platform.

Why Transition from VBA?

In many ways, VBA has been a victim of its own success. Its tight integration with Office and very usable and immediate development environment make it hard to beat. However, its been with us since 1991, the same year that Tim Berners-Lee created the first website, which is still running today, but for historical rather any aesthetic or functional reasons.

Although VBA is as far removed from its 1991 forefather as todays HTML5 sites are from that first website, every version of Office for as long as I can remember has come with a threat that perhaps VBA will not be supported. Office 2008 for Mac did not support VBA, but it was back again by public demand in Office 2011. Office 2016 has just been released, and we can all breathe a sigh of relief to see that VBA is still there. But Microsofts focus is shifting to Office 365 from Office for the desktop. According to Satya Nadella of Microsoft, the most strategic developer surface for us is Office 365.

With incompatibilities between 32-bit and 64-bit versions and between Office for Mac and Windows, and with a reliance on references to libraries that are no longer shipped with Windows, VBA becomes harder for Microsoft to support and for us to use.

Im a longtime proponent and fan of VBA. Im not alone, considering the Office development section of my website still generates almost a million annual page views, and there are still many active VBA communities and forums around. VBA continues to enjoy immense popularity, but (sadly) its probably time to move on, as one of these days it really will no longer be shipped with Office.

This book will show you by example how to do some of the same things you do today in VBA, but in Apps Script. The examples will use the Google Apps platform, but well also look at the Microsoft JavaScript API.

Intended Audience

You are probably already a VBA or .NET developer. You might even already be an Apps Script developer who needs to understand something about VBA to assist with a migration, or perhaps you simply want to learn Apps Script. This is not intended to be a book for beginners, and best fits those who are already comfortable with one or more development languages.

Its not necessary to already know JavaScript, but things will move faster if you do. This is not a JavaScript tutorial, but this book will introduce the language components and syntax and provide enough examples to enable the proficient use of Apps Script.

For add-ins and add-ons (extending Docs and Office with client-side web apps), and the HtmlService sections of the book, youll need some understanding of HTML, CSS, and the DOM.

The VBA Library

The overall objective of this book is to demonstrate how to apply Apps Script services best practices to solve problems common across Office automation platforms. A key output is a library that emulates many built-in VBA functions in JavaScript. This will allow you to port some of your VBA code and structure to Apps Script with minimal changes, while concentrating on the Apps Script services capabilities.

Reading Order

The first part of the book compares the capabilities of each platform, then moves on to the fundamentals of the JavaScript language, emphasizing how it differs from VBA. That is followed by a long reference section containing an implementation in JavaScript of each of the main VBA built-in functions, as well as some of the utility objects.

If you decide to use this library, it means that you can still write VBA-style code that calls VBA built-in function names, instead of using the native JavaScript equivalent. Alternatively, you can refer to the translations and implement those when you port your applications.

The rest of the book deals with each Google Apps Script service that has an equivalent in VBA (and a few that dont), and will generally show you the contrast in navigating and interfacing between the respective object models.

There are both tutorials and reference material, and the order in which you read them is not especially important, although some of the examples refer back to previous chapters and concepts. It is likely that you already have experience in some of the subjects (or dont plan to use some of the services covered). Its not really required that you read the content sequentially.

In summary, the scope of the material is not only the contrast between how to do things in Apps Script and VBA, but also how to get things done in the Google universe. This will ease the transition to Google Apps, regardless of where you are coming from.

Apps Script is both young and versatile, with new capabilities being added (and old ones being deprecated) regularly, and unlike with VBA, you dont have the option to get stuck on an old version (even if you want to).

The Examples

The code illustrations are a mixture of snippets and longer projects, but they quickly become challenging, using the kind of patterns found in real-world scenarios. This is by design. After all, you are probably already an accomplished developer and Hello, World"level tutorials are not going to be much help for quickly porting VBA applications that have already benefited from significant investment in intellectual and financial capital.

Next page
Light

Font size:

Reset

Interval:

Bookmark:

Make

Similar books «Going GAS: from VBA to Google Apps Script»

Look at similar books to Going GAS: from VBA to Google Apps Script. We have selected literature similar in name and meaning in the hope of providing readers with more options to find new, interesting, not yet read works.


Reviews about «Going GAS: from VBA to Google Apps Script»

Discussion, reviews of the book Going GAS: from VBA to Google Apps Script and just readers' own opinions. Leave your comments, write what you think about the work, its meaning or the main characters. Specify what exactly you liked and what you didn't like, and why you think so.