+ Reply to Thread
Results 1 to 11 of 11

Emailing Spreadsheets with embedded Macros

  1. #1
    Registered User
    Join Date
    05-20-2012
    Location
    Kent
    MS-Off Ver
    Excel 2003 and 2010
    Posts
    10

    Emailing Spreadsheets with embedded Macros

    Whilst I have a reasonable understanding of Access, I am a dim-wit when looking at Excel code ... please advise me.

    I am Emailing out Excel spreadsheets to our Club Executive which now contain macros and VBA.
    (Thanks to this forum that I am able to do that!)

    It seems that some ISP's don't like the attachments, as they see them as a threat (or at least a potential threat).

    Apart from a freeze panes and a filter on a row, I don't need anything fancy for them to run. Just the actual data in the rows and columns.

    They just need the membership details .... all the code/macros was written to drag the data from access tables and format it.

    As a possible solution, I wondered whether it would be possible to do a complete copy on each page's data and paste it back on the same page as PasteSpecial .. values.
    And then delete all the macros and VBA code.

    Does this sound stupid?

    My thinking is that without the code, the ISPs will probably accept the attachments, as I never had problems with the spreadsheets that I used to generate in Access ... possibly because there was no code/macros in them.

    Or is there a simple solution ?... but one which must not involve the receivers of the Excel spreadsheets changing anything their end.

    I hope this all makes sense!

  2. #2
    Forum Contributor
    Join Date
    12-04-2009
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    127

    Re: Emailing Spreadsheets with embedded Macros

    Do you run the macro manually, then send the spreadsheet?

    If yes, then you can store the macros in your PERSONAL.XLS file.

    run the macros on the workbook that you need to run it on, then send a normal spreadsheet to your recipient.

  3. #3
    Registered User
    Join Date
    09-02-2011
    Location
    Dayton, Ohio
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Emailing Spreadsheets with embedded Macros

    When I need to send an *.xlsm through an email, I just change the file extension. If you save it to your desktop as an *.xlsm then click on the file to rename it and change the extension to *.xslx, your email server should let it go through. I haven't had any fail yet. Good luck. (Just remember to save it on the other end, and change the extension back to *.xlsm for the macros to work.)

    Billy
    Last edited by LewisWA02; 06-01-2012 at 01:39 PM. Reason: clarification

  4. #4
    Registered User
    Join Date
    05-20-2012
    Location
    Kent
    MS-Off Ver
    Excel 2003 and 2010
    Posts
    10

    Re: Emailing Spreadsheets with embedded Macros

    Robotatcha21010 Thnaks for your response.
    Using Access 2003 I build 5 tables.
    I have 5 Excel 2003 spreadsheets each one of which , using code in Private Sub workbook_open() in Thisworkbook, I 'automatically' import the Access table, and massage it using VBA and Macros. It then, again automatically, gets attached to an email and sent to the recipient.

    So to answer your question, No ... I don't send it manually.

    I am not sure what a PERSONAL.XLS file is ... I shall research and see it I can work something out using it.
    Thank you.

  5. #5
    Registered User
    Join Date
    05-20-2012
    Location
    Kent
    MS-Off Ver
    Excel 2003 and 2010
    Posts
    10

    Re: Emailing Spreadsheets with embedded Macros

    Thanks LewisWA02.
    I appreciate your assistance.
    The files all have an extension .xls
    The macros work using this extension.
    I ran Norton360 against them and sent a copy of the 'cleared' status with the spreadsheets, so Norton thought they were OK.
    I was hoping for a solution which doesn't involve my users having to do anything other than open the spreadsheets.

    Any further ideas?

  6. #6
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Emailing Spreadsheets with embedded Macros

    Try zipping the files & password protecting the zip files
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  7. #7
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Emailing Spreadsheets with embedded Macros

    Hi MrChips

    Put all your code is a separate Macro book and the data in a separate Data workbook. Massage the Data file with the Macro file. Your Data file will not have any code in it.
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

  8. #8
    Registered User
    Join Date
    05-20-2012
    Location
    Kent
    MS-Off Ver
    Excel 2003 and 2010
    Posts
    10

    Re: Emailing Spreadsheets with embedded Macros

    RoyUK.

    I did as you suggested and my recipient was able to open it OK.
    Thank you.

  9. #9
    Registered User
    Join Date
    05-20-2012
    Location
    Kent
    MS-Off Ver
    Excel 2003 and 2010
    Posts
    10

    Re: Emailing Spreadsheets with embedded Macros

    Jaslake.

    Roylake seems to have answered my problem ... but if I have further issues I will definitely try your suggestion.
    All I will have to do is try to find out how to do it!

    Thank you both for your time and advice

  10. #10
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Emailing Spreadsheets with embedded Macros

    Hi MrChips

    There's an example of this approach in Post #25 of this link
    http://www.excelforum.com/excel-prog...n-columns.html

    All the code exists and runs from the Macro Book...no code need exist in the Data File.

  11. #11
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Emailing Spreadsheets with embedded Macros

    Roylake - twinned

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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