+ Reply to Thread
Results 1 to 9 of 9

Sending emails

  1. #1
    Forum Contributor
    Join Date
    07-27-2009
    Location
    montreal, canada
    MS-Off Ver
    Excel 2003
    Posts
    230

    Sending emails

    Yes i have read Ron de Bruin's tutorials.

    Hi,
    I'm trying to send sheets to an email.
    My code up to now saves a copy of the sheet in a file, and I send that file out.
    Unfortunatly when I run my macro it ends with the email opening, the file being attached, and I need to input the email adress. Also, i need to automatically overwrite what is in the folder.

    My code looks nothing like the one on Ron's tutorials.
    can anyone help out:



    Please Login or Register  to view this content.
    Last edited by Sibrulotte; 01-26-2010 at 10:32 AM.

  2. #2
    Forum Contributor
    Join Date
    07-27-2009
    Location
    montreal, canada
    MS-Off Ver
    Excel 2003
    Posts
    230

    Re: Sending emails

    Alright, sorry,
    I changed it.


    I also, tried to copy what i thought would work into my Module from Ron's tutorial.
    Here's what it gives me (still doesn't work):

    Please Login or Register  to view this content.

  3. #3
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Sending emails

    In the 2nd code you're not actually doing anything with the Item you're creating, ie you're missing any one of:

    Please Login or Register  to view this content.
    prior to the End With statement... the first will mail, second will show dialog and third will save as draft.

    Regards the first code, if you just want to send it and are not fussed about setting Body content then use ActiveWorkbook.SendMail method.

  4. #4
    Forum Contributor
    Join Date
    07-27-2009
    Location
    montreal, canada
    MS-Off Ver
    Excel 2003
    Posts
    230

    Re: Sending emails

    Thank you, that was weak...


    Although, I might have missed the line that forgoes the message box from outlook:

    "A program is trying to automaticaly send an e-mail on your behalf..."

  5. #5
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Sending emails

    Regards Security Prompt... I would refer you to Ron de Bruin's site but...

  6. #6
    Forum Contributor
    Join Date
    07-27-2009
    Location
    montreal, canada
    MS-Off Ver
    Excel 2003
    Posts
    230

    Re: Sending emails

    HAHA! Thanks,
    realy can't figure out in his whole script what is there for bypassing Outlook's security prompt...

    I can still click yes... for the 8 sheets I need to send out...

  7. #7
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Sending emails

    His site really does cover all the options open to you... http://www.rondebruin.nl/mail/prevent.htm

    Other than those mentioned there's not a huge amount you can do I'm afraid.

  8. #8
    Forum Contributor
    Join Date
    07-27-2009
    Location
    montreal, canada
    MS-Off Ver
    Excel 2003
    Posts
    230

    Re: Sending emails

    Thanks Chief, that does help.

    I'm not 100% solved though.
    I'm using the .display, then send button.
    But outlook is saying the object has been deleted.
    But there's no code to delete any object.

    Maybe lunch will help me wrap my head around this.

  9. #9
    Forum Contributor
    Join Date
    07-27-2009
    Location
    montreal, canada
    MS-Off Ver
    Excel 2003
    Posts
    230

    Re: Sending emails

    Well the "Click yes" solution worked for me.
    Thank you Donkey Ote

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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