1

I want to send an email with bcc option. Email works fine but I cannot use bcc.

How can I send a bcc with the info given from a range or cell value?

See my code below

GmailApp.sendEmail(emailAddress, subject, message, {
        bcc: '[email protected]',
       // attachments: [blobs[i]], kmlijst
       attachments: [blobs[i], kmlijst.next()]
      });

bcc: '[email protected]' has to be a cell vallue from

      var emailRange2 = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Lees_deze_informatie").getRange("d3");
var emailAddress2 = emailRange.getValues();
1

1 Answer 1

0

You are extracting the value from a single cell (D3), so you would use getValue().

DELETE: var emailAddress2 = emailRange.getValues();

SUBSTITUTE: var emailAddress2 = emailRange.getValue();

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.