+ Reply to Thread
Results 1 to 11 of 11

Need to email a range of cells, two columns, 8 sheets. Possible?

  1. #1
    Registered User
    Join Date
    02-18-2014
    Location
    Tennessee, USA
    MS-Off Ver
    Excel 2010
    Posts
    27

    Need to email a range of cells, two columns, 8 sheets. Possible?

    I tried the search, and I guess the terms I used didn't return anything useful, I've tried google, nothing.

    Is it possible to email (using Outlook 'Office 2013') two columns, A and F, from 8 separate sheets (all A and F's on each sheet) in the same workbook, but each sheet has a different amount of rows? I've seen the posts showing how to email a rectangular selection, etc, but I don't need a lot of the stuff on the sheet going across on the email, and I've got too many formulas, etc to start messing around rearranging stuff on the sheet.

    So,

    Sheet1, A1-A55 & F1-F55
    Sheet2, A1-A55 & F1-F55
    Sheet3, A1-A55 & F1-F55
    Sheet4, A1-A36 & F1-F36
    Sheet5, A1-A36 & F1-F36
    Sheet6, A1-A63 & F1-F63
    Sheet7, A1-A63 & F1-F63
    Sheet8, A1-A63 & F1-F63

    Then, said selections would email off to two people (with the caveat that is may end up being 3 people) as an attachment?

    And could I specify in the subject line something like 'Raw Data Sent [date & time]' and even the 'from email' as I have 2 email accounts and I'd like to use the 'other' one?

    I'll end up attaching any code to a button, so I can just open up the spreadsheet and hit the button and then close the spreadsheet.

    Thanks in advance for any help/code I'm provided.

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,410

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    Suggest you post a sample workbook with some typical data.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    02-18-2014
    Location
    Tennessee, USA
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    That I tried, manage attachments allows me to upload said spreadsheet, but then clicking the little 'attachment' in advanced mode yields no results to click.

    So I've attached a screenshot of the layout as I don't want to provide personal data like is suggested.

    Example.jpg

  4. #4
    Registered User
    Join Date
    02-18-2014
    Location
    Tennessee, USA
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    Guess this is not possible?

  5. #5
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,012

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    .
    .
    Try this. Paste this macro into a routine module. There is another macro in the project also - review after download of file.

    Please Login or Register  to view this content.
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    02-18-2014
    Location
    Tennessee, USA
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    Thanks Logit, I've brought that code over to my spreadsheet and I've changed what I needed to do to match my data, etc. In principal it works, but I have a couple of questions.

    1) is there a way to copy over the formatting? i.e. some of the cells are red in colour (based on conditional formatting) and some are green. Also, the cells have the boxes around them.
    2) is there a way to make this turn into an attachment into the email? rather than copy and paste the contents into the email ready to hit send?

    Again, thanks for helping me out with this.

  7. #7
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,410

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    Variation on a theme

    This example copies the data to a new sheet within the workbook, moves that to a new workbook, and then sends the new workbook as an attachment.

    Please Login or Register  to view this content.
    Last edited by TMS; 04-10-2017 at 05:47 PM. Reason: Amend code

  8. #8
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,012

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    .
    .
    Creates a PDF file used as an attachment:

    Please Login or Register  to view this content.
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    02-18-2014
    Location
    Tennessee, USA
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    @Logit @TMS.

    Thank you both for your input, time, code and expertise, I've managed to knock together something, using your code and a few tweaks, that works for my needs.

  10. #10
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,410

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    You're welcome. Thanks for the rep. Thanks for the feedback.

  11. #11
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,012

    Re: Need to email a range of cells, two columns, 8 sheets. Possible?

    You are welcome.Thank you.

    Cheers

+ 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. Macro to copy range of cells (2 columns) to outlook email body
    By thobbs in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-09-2016, 12:29 PM
  2. create new sheets, arrange columns, add hyperlink, send as html email
    By shootstill in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-16-2014, 03:03 PM
  3. email to range of cells vba
    By milo1984 in forum Excel General
    Replies: 3
    Last Post: 12-07-2013, 10:55 AM
  4. VBA code to loop through 3 columns, chk for 2 conditions and email txt from the cells
    By philipcph in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-30-2013, 01:14 AM
  5. [SOLVED] Macro to Unprotect sheets-unlock range of cells-protect sheets
    By jrace in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-09-2013, 10:45 AM
  6. Email Range of Cells with a picture
    By paxile2k in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-10-2011, 11:52 AM
  7. send email with email addresses in a range of cells
    By Craig in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-10-2005, 05:05 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