+ Reply to Thread
Results 1 to 3 of 3

MACRO to export to PDF and email

  1. #1
    Registered User
    Join Date
    08-29-2012
    Location
    australia
    MS-Off Ver
    Excel 2007
    Posts
    86

    MACRO to export to PDF and email

    Hi
    First off I am not great when it comes to VBA. What I am looking at doing is having a button that you will click on and it will convert the specific print area (I have 3) to a PDF and come up to email, so you can than select who you want to send it. I have a macro set up at the moment but you have to select the area and than it saves to file, I would prefer if possible that it automatically select area, convert to a PDF and come up to email.
    Attached is an example of the report
    Attached Files Attached Files

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

    Re: MACRO to export to PDF and email

    .
    Generally speaking , your desired approach will work best if you have the same range of cells to be saved as a PDF.

    If you are sometimes changing the range to something different, it would be best to continue with the current design ... or ... you will need to edit the code enabling
    the user to select different set ranges from say a DROP DOWN list or other method of differentiating between the various ranges.

  3. #3
    Forum Contributor
    Join Date
    06-07-2016
    Location
    Manila
    MS-Off Ver
    365
    Posts
    292

    Re: MACRO to export to PDF and email

    you can try:
    for the export to PDF - the CCI.range can be changed depending on what range you want to be published as PDF. you can declare 3 range if you are going to save 3 ranges to PDF
    Please Login or Register  to view this content.
    for the email:

    Please Login or Register  to view this content.
    and make sure you tick the "Microsoft Outlook Object Library" in your References
    Last edited by aarona; 12-13-2018 at 05:44 AM. Reason: update

+ 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. Export Sheets to Workbook and Email
    By Simon.xlsx in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-20-2014, 09:51 AM
  2. export to pdf not attaching to the email
    By dantray02 in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 01-30-2014, 01:23 PM
  3. Need Export Macro to text file based on email address
    By techniner in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 12-19-2013, 01:21 PM
  4. export outlook 2007 email into excel with subject and body of email
    By akulka58 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-25-2013, 02:37 PM
  5. VB code to export to PDF and email
    By hcabs99 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-03-2013, 07:10 AM
  6. I would need a macro to export data from base example workbook to export worbook
    By slato8 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-01-2012, 11:21 AM
  7. [SOLVED] Export to email body each column is new row
    By mvtechnet in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-15-2012, 07:59 AM

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