+ Reply to Thread
Results 1 to 4 of 4

VBA to Send eMail with PDF Attachment from SharePoint File

  1. #1
    Forum Contributor Gtrtim112's Avatar
    Join Date
    04-12-2013
    Location
    Alabama, USA
    MS-Off Ver
    Excel 2016
    Posts
    332

    VBA to Send eMail with PDF Attachment from SharePoint File

    Happy New Year!

    I believe this is relatively simple so I'm hoping someone can solve it for me.
    I have the code below in a workbook, which saves the Excel sheet as a PDF and then attaches to an email in Outlook. I've used this code for years with no issue but the file has always been on a local hard drive when the macro was used.
    The file I'm using today is stored in SharePoint and used by various people. For some, the macro isn't working at all. My assumption is that it's having an issue when trying to create the temporary file name to SharePoint, then kill that file name.

    Can someone look at the VBA code here and suggest a way to make the temporary file path direct towards the local drive versus the SharePoint site that the file is located in?

    Thank you for taking a look!

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

  2. #2
    Forum Expert
    Join Date
    10-11-2021
    Location
    Netherlands
    MS-Off Ver
    365
    Posts
    1,386

    Re: VBA to Send eMail with PDF Attachment from SharePoint File

    What if you run this? You can't use kill on sharepoint web links.

    Please Login or Register  to view this content.
    Last edited by JEC.; 01-02-2024 at 03:51 PM.

  3. #3
    Forum Contributor Gtrtim112's Avatar
    Join Date
    04-12-2013
    Location
    Alabama, USA
    MS-Off Ver
    Excel 2016
    Posts
    332

    Re: VBA to Send eMail with PDF Attachment from SharePoint File

    What if you run this?...
    Perfect... so much more simple coding also.

    Thank you very much for the quick reply!

  4. #4
    Forum Expert
    Join Date
    10-11-2021
    Location
    Netherlands
    MS-Off Ver
    365
    Posts
    1,386

    Re: VBA to Send eMail with PDF Attachment from SharePoint File

    You're welcome! We like simple

+ 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. Pulling attachment from the email send by particular email
    By Ratna.Snepal in forum Outlook Programming / VBA / Macros
    Replies: 0
    Last Post: 07-30-2022, 12:34 AM
  2. Google sheet: Help to attachment file from Google Drive and send email fill in Google Form
    By sbv1986 in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 0
    Last Post: 03-01-2021, 10:47 PM
  3. [SOLVED] Send Email from VBA Excel when file is on sharepoint
    By AlexxBI in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-08-2019, 10:18 AM
  4. Macro to send email with attachment for each unique email Ids
    By vijanand1279 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-06-2014, 07:12 AM
  5. [SOLVED] send email with attachment
    By ks1102 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-06-2013, 02:29 AM
  6. Generate path of a file in column and send email as attachment based on a cell value
    By anchuri_chaitanya in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-04-2013, 02:01 AM
  7. How to send email with attachment
    By staciam in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-04-2011, 12:19 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