+ Reply to Thread
Results 1 to 2 of 2

Sending emails from a cell value via google sheets.

Hybrid View

  1. #1
    Registered User
    Join Date
    12-20-2018
    Location
    London
    MS-Off Ver
    Online
    Posts
    12

    Sending emails from a cell value via google sheets.

    https://docs.google.com/spreadsheets...gid=1451036760

    This is the sheets I am working on, on the Quota Capacity Recommendation sheet I am trying to have emails automatically sent if the value in the column "Actual productivity per-hour" is >(1.15*"Quantity demanded per-hour") or Actual productivity per-hour (<1.15*"Quantity demanded per-hour").

    This is what i have so far but i am getting a error one the MailApp.sendEmail line.

    function myFunction() {

    var ss = SpreadsheetApp.getActive();

    var sheet = ss.getSheetByName('Quota Capacity Recomendation');

    var qdph = sheet.getRange(F2).getValue();

    var apph = sheet.getRange(G2).getValue();

    var rc = sheet.getRange(I2).getValue();

    var name = sheet.getRange(A2).getValue();


    {

    if(apph>(1.15*qdph) || apph<(1.15*qdph))

    {

    MailApp.sendEmail(voluntaryamnesia@gmail.com,+name+ Quota Recomendation, +name+ has reccomended quota change of:, +rc+ “.”);

    }

    }

    }

  2. #2
    Forum Expert CK76's Avatar
    Join Date
    06-16-2015
    Location
    ONT, Canada
    MS-Off Ver
    MS365 Apps for enterprise
    Posts
    5,973

    Re: Sending emails from a cell value via google sheets.

    Try GmailApp instead of MailApp.
    "Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something."
    ― Robert A. Heinlein

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Google sheets: Send emails with a click of a button when spreadsheet is updated
    By rayted in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 0
    Last Post: 08-07-2018, 09:31 AM
  2. Sending Emails containing cell info - Formatting Help
    By marcosis in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 12-20-2017, 05:36 AM
  3. [SOLVED] Sending Emails based on content in a single cell
    By chunkyp in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-13-2017, 08:54 AM
  4. email row contents based on cell values (google sheets populated by google forms)
    By reedg in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 0
    Last Post: 01-13-2016, 02:55 PM
  5. [SOLVED] Sending Outlook emails from Excel; Limits to three emails only?
    By BPSJACK in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-29-2013, 06:53 AM
  6. Sending Emails from Excel Dependent Cell
    By dpgleason in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 11-03-2011, 03:57 PM
  7. Sending macro emails using excel: Send emails with their passwords.
    By loveisblind in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-12-2009, 03:16 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1