How To Automatically Send Customized Emails With Attachments Using Excel Macros

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ต.ค. 2024
  • In this tutorial we would learn:
    1. How to send Emails Using Excel Macros
    2. How to Attach files in an Email using Excel Macros

ความคิดเห็น • 138

  • @davide740
    @davide740 7 หลายเดือนก่อน

    Great video! What would the code be if we were to use simple macro code with no Microsoft Outlook 16.0 object library? I understand it would be more flexible as it can work on all computer without activating an additional library. thanks

  • @leroymentor9932
    @leroymentor9932 ปีที่แล้ว +2

    I'm so grateful for this video. It's going to save me a lot of time, thanks!

  • @kasragg2715
    @kasragg2715 ปีที่แล้ว

    It was so helpful, Would you please let me know how we can modify "Email Address" of Sender too? Thanks

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      for that you will need to have rights of the mailbox from whose email id you wish to send the emails

  • @daffaburhan6675
    @daffaburhan6675 ปีที่แล้ว

    Great video! Can I setting to send that email automatically everyday at specific time?

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      you will have to use windows scheduller for the same

  • @andrewbeal6443
    @andrewbeal6443 ปีที่แล้ว +2

    Thanks! Very well done. What is the code to delay the sending of the emails to a specific date/time?

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว +3

      You can set up a scheduller job in windows to have this macro execute at a specific time

  • @vorkpalur
    @vorkpalur 6 หลายเดือนก่อน

    Hi, first of all, thank you very much for sharing this. I have a question, is it possible to do the same with Gmail account without Outlook?

    • @AutomationMadeEasy
      @AutomationMadeEasy  6 หลายเดือนก่อน

      yes, refer below tutorial:
      th-cam.com/video/c7S0-3x9hFw/w-d-xo.html

  • @alyaalaksmigodwin1197
    @alyaalaksmigodwin1197 หลายเดือนก่อน

    Thankyou so much! It helped me a lot

  • @darshilshah9755
    @darshilshah9755 ปีที่แล้ว

    This really helped alot. Need one more help though. I have access to multiple mailbox, this code sends mails from default email, however, i want to send mail from other id. Please let me know the line of code required.

  • @亦涵张
    @亦涵张 ปีที่แล้ว

    Amazing contents! Can I please ask a further question? I want to reply on top of a specific email, reply it with customized content like what you did here, while still keeping the previous email thread… somehow I can’t keep both at the same time? Much appreciated if you could provide help on this! Thanks in advance

  • @MyDearFriend
    @MyDearFriend 7 หลายเดือนก่อน

    amazing video, is there a way to have it send emails based on an if statement. for example If a date is coming up?

    • @AutomationMadeEasy
      @AutomationMadeEasy  7 หลายเดือนก่อน +1

      certainly it can be customized but it all depends on structure of data and conditions

  • @samanthaworrall1918
    @samanthaworrall1918 ปีที่แล้ว

    Thank you so much!! This has saved me hours of work!! Is there a way to add my email signature also to send it from a joint or alternate email address?

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      Glad you found it helpful.
      Will try to find a solution for it. Dont have it right now

  • @mehdibakhtiari300
    @mehdibakhtiari300 2 หลายเดือนก่อน

    You made it really easy to understand!

    • @AutomationMadeEasy
      @AutomationMadeEasy  2 หลายเดือนก่อน

      Thank you

    • @mehdibakhtiari300
      @mehdibakhtiari300 2 หลายเดือนก่อน

      I have still problem with the attachments. My VBA deletes first the pervious emails then attaches the PDF to the new one. At the end an email remains with 10 attachments.@@AutomationMadeEasy

  • @janinehadia3036
    @janinehadia3036 22 วันที่ผ่านมา

    How so send it from different email address for example if i am going to use the generic mailbox on behalf of my department?

  • @YaelShriki
    @YaelShriki ปีที่แล้ว

    Hi! Thank you so much for this video it will be such a huge time saver for me!
    I'm currently trying to get this set up but i get an error with the "attachments.add strfolder & "\" & strfile" line.
    When I run the code I get an error saying "the drive is not ready. Verify that the desk is in the drive and that the door is closed" Do you know how to amend this?
    Sincerely,

    • @YaelShriki
      @YaelShriki ปีที่แล้ว

      I've added the folder to my desktop and repasted the path into the folder line and i still get an error for the attachment line saying " file name or directory name is not valid."

    • @gaspumprepairservice7009
      @gaspumprepairservice7009 8 หลายเดือนก่อน

      @@YaelShrikibe certain you’re specifying the correct drive letter and path -> “C:\DATA\REPORTS”, for example. Notice my example did not end with a backslash as the code provides one.

  • @wolfenstein6288
    @wolfenstein6288 2 ปีที่แล้ว

    Excellent video , i want to know, i have to keep the default mail body which is pre set as signature on my outlook and rest of the things should be done via this excel and can we add more file name columns if i have to send 2 or 3 invoices on same ID

  • @saptarshidalal5765
    @saptarshidalal5765 ปีที่แล้ว

    This is really helpful. But how can I add an image in this email? could you advise on this please.

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      You can attach the image. Attachment example is explained in the tutorial.

    • @saptarshidalal5765
      @saptarshidalal5765 ปีที่แล้ว

      ​@@AutomationMadeEasyI do not want to attach it. The image will be in the mail body

  • @sandeshpadigela0
    @sandeshpadigela0 ปีที่แล้ว +1

    This is a really good trick, thanks for taking the time to share knowledge, I do have a question extent of this. 1) We have employee performance data with multiple details, 2) we get this data week basis 2) We select each employee's data from the validation list 3) We take this screenshot 4) Copy the screenshot in an email 5) Send that to employee - I see challenge to select 20 employees from data validation list and copying screenshot, is there any way we can work on this?

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      Well seems feasible but will need lots of customization.

  • @j.dasilva4567
    @j.dasilva4567 2 ปีที่แล้ว +2

    Very good. I was doing the same in a more complex way, ur way is so much better. Thanks for this. Could u please show how to add default signature? Thank u.

    • @AutomationMadeEasy
      @AutomationMadeEasy  2 ปีที่แล้ว +2

      let me check and get back

    • @aznbspikey
      @aznbspikey ปีที่แล้ว +1

      @@AutomationMadeEasy did you find out?

  • @vipulprajapati2797
    @vipulprajapati2797 ปีที่แล้ว

    Hello sir, Your VBA programming was outstanding. I have one query. suppose on the third row there is no attachments so how can i make programming for those client id only who has attachments and no mail sent for those who has no attachments??
    I am waiting for your reply.
    Thank you

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      u can insert an if condition before the code which sends email. Syntax given below
      Assume filepath is at cell D20
      filepath = ThisWorkbook.Sheets("SheetName").Range("D20").text
      if filepath "" then
      'code to send email
      End if

    • @vipulprajapati2797
      @vipulprajapati2797 ปีที่แล้ว

      Thank you sir For your reply. I have One another question. I have applied this programming for sending multiple files to individual recipients and I was succeeded but when some persons doesn't have multiple files say only one file and other have more than one files then what should i do in programming. I have tried but didn't succeeded in this. I have been eagerly waiting for your reply@@AutomationMadeEasy

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      @@vipulprajapati2797 - Well it depends how your data is formatted. the sloution needs to be customized based on data. If you need consultation/training write into info@automationandagile.com

  • @deepali8939
    @deepali8939 2 ปีที่แล้ว +2

    Hello, if i want to choose email id for TO: and CC: how to customize it?

  • @selvan1264
    @selvan1264 2 ปีที่แล้ว +1

    Thanks for the video. How to save the outlook email draft into local folder?

  • @xreeyJ
    @xreeyJ ปีที่แล้ว +2

    Hi sir, appreciate your video. Very helpful. However i have two questions which is 1. How to indicate company logo under signature? 2.How to indicate multiple email address?

    • @hongxiliu4282
      @hongxiliu4282 ปีที่แล้ว

      Hi there, I got the same problem.. when I insert multiple emails on Excel cell, it doesn't seem to be able to detect when the email is generated and i need to click them one by one. Have you found a way yet?

  • @JLa-lw6pe
    @JLa-lw6pe 3 หลายเดือนก่อน

    Can you send an excel spreadsheet using this code?

  • @dhirajsuryawanshi4510
    @dhirajsuryawanshi4510 7 หลายเดือนก่อน

    Great video. Bro I want to create automation in excel to auto send Birthday wishes email. Could you please help me on this. I got the project

    • @AutomationMadeEasy
      @AutomationMadeEasy  7 หลายเดือนก่อน

      for trainings/consultation write into info@automationandagile.com

  • @antothomas7523
    @antothomas7523 ปีที่แล้ว

    This is very helpful. Can you also please share the code for sending these emails using outlook web application.

  • @ericndega
    @ericndega ปีที่แล้ว +2

    Great and amazing insights!

  • @himanshuarora14
    @himanshuarora14 7 หลายเดือนก่อน

    I want to send follow up emails from the same email threads that they were send from last time, how can I do that?

  • @robydc56
    @robydc56 2 ปีที่แล้ว

    Hello, great video, thanks.
    1 question, please: if I want to set the Amount in blue color, how can I do? Thank you!

  • @Micomicooo-eo5ee
    @Micomicooo-eo5ee 2 หลายเดือนก่อน

    Hi sir how can I make part of the text bold?

  • @EZEQUIELGOMEZHORVITZ
    @EZEQUIELGOMEZHORVITZ ปีที่แล้ว

    Could you provide a link to your blog with the code?

  • @SadamHussain-yx3uh
    @SadamHussain-yx3uh 2 ปีที่แล้ว

    Thank you for your guidance. It's worked

  • @123naimish
    @123naimish 2 ปีที่แล้ว

    Hello Sir, Excellent tutorial it is perfectly working.
    I have query, if I need to add my outlook signature in email, then how the code will work?

  • @sanjeebmaharjan
    @sanjeebmaharjan ปีที่แล้ว

    Best, Thank you so much.

  • @shelbybennion4585
    @shelbybennion4585 ปีที่แล้ว

    This was soooo helpful. Thank you!

  • @eltotsira1000
    @eltotsira1000 7 หลายเดือนก่อน

    Hi, can you share the VBA code so I can copy paste. Thank you.

  • @deepakbhatia8839
    @deepakbhatia8839 7 หลายเดือนก่อน

    Just few questions about this is that i have written the code as per the video however mail is being sent repeatedly n number of times and in my data multiple records are tagged to one single client id request you to kindly how to send the one consolidated email basis the client id instead of sending multiple emails basis the number of rows

    • @AutomationMadeEasy
      @AutomationMadeEasy  7 หลายเดือนก่อน

      need to see how your data is structured.

    • @deepakbhatia8839
      @deepakbhatia8839 7 หลายเดือนก่อน

      @@AutomationMadeEasy please assist how can I share the data samples for your reference.

    • @AutomationMadeEasy
      @AutomationMadeEasy  7 หลายเดือนก่อน

      for training/consultation write into info@automationandagile.com

  • @shubhamyadav-nd4zx
    @shubhamyadav-nd4zx 2 ปีที่แล้ว +1

    Help me to make a VBA code to send 20 files. Just like you did it need to add up a little bit more. Let me give details a little bit. Each mail has a different attachment and mail body. Like if I am sending my 1st mail. I will open that excel file, go to a particular sheet, copy data, paste it to the email body, and attach that same file as an attachment. Once the mail is ready then that file gets closed. And then with 2nd mail and it will go on for 19 times.

  • @michaellawrence6009
    @michaellawrence6009 ปีที่แล้ว

    Is there away to add CC's

  • @bertongputik1015
    @bertongputik1015 ปีที่แล้ว

    Hello! appreciate your video, just asking why my result is only sent to top of receiver, not the same with your result sent to all receiver (6) and I have an error to whole line (With objEmail upto End With). please help me to resolve this problem. Thank you

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      need to see your code and spreadhseet to understand the error

  • @RadMoulk-ok3nn
    @RadMoulk-ok3nn ปีที่แล้ว

    how to send a message with images like in signature since excel does not accept images in sheets

  • @shankaraellamula8463
    @shankaraellamula8463 ปีที่แล้ว

    Thank you very much...This was very informative and easy to understand.....😊

  • @emilvincentgomez8977
    @emilvincentgomez8977 ปีที่แล้ว

    Hello. Useful presentation. I have a query. When i am entering the data which has alphabets, numbers and special characters it is popping error. Please help me.

  • @pramodofindia
    @pramodofindia 2 ปีที่แล้ว +1

    Can this be modified to work with Gmail? How? Thanks in advance.

    • @pramodofindia
      @pramodofindia 2 ปีที่แล้ว

      Thanks, but the reason why I want to use Gmail is, that I don't have Outlook.

  • @Talkatalkk
    @Talkatalkk หลายเดือนก่อน

    Hello how to contact you ?

  • @kristinwillers6723
    @kristinwillers6723 2 ปีที่แล้ว

    Hello - I wish to add multiple attachments to the email send, up to 4. How would I identify the different columns and references to ensure the files are attached correctly? I did not see this option on your blog.
    Thank you,

  • @praneshkumarrathinasamy7740
    @praneshkumarrathinasamy7740 ปีที่แล้ว

    Amazing content. Thanks a lot

  • @randomrandy3059
    @randomrandy3059 10 หลายเดือนก่อน

    I have a mac, and been on mac because of my pro audio interest... Mac is not so Microsoft friendly. Alot of the features that could make my system more efficient are on Windows!
    I have to DL ODBC Drivers to connect to the SQL MicrosoftServer to be able to do this. And thats where I get stuck. Im on a mission.
    Any Mac users out there trying to accomplish this task?

  • @9r266
    @9r266 ปีที่แล้ว

    Sir you're great thanks

  • @test4629
    @test4629 ปีที่แล้ว

    You are amazing my friend! Thanx allot

  • @haridx05
    @haridx05 2 ปีที่แล้ว +1

    How to add cc and Bcc.can you plz add that

  • @reynandtrinidad4228
    @reynandtrinidad4228 2 ปีที่แล้ว

    Sir, how about email will not be sent (pop up as new email) & can still be updated manually to add tables & pictures? Thanks in advance

  • @nagakishorel1368
    @nagakishorel1368 6 หลายเดือนก่อน

    If 'To' email Id cell is blank then Email shouldn't go what code we need to enter ?

  • @bhumapoojithreddy6737
    @bhumapoojithreddy6737 8 หลายเดือนก่อน

    I have two mails in my outlook one is personal and business so when I click send email button it goes from personal mail so can you please me to change my sender email address

    • @AutomationMadeEasy
      @AutomationMadeEasy  8 หลายเดือนก่อน

      try adding below line of code just befor .send
      .SentOnBehalfOfName = "Email ID"
      Replace email id with actual email id with which you wish to send the emails

  • @archiedelarosa499
    @archiedelarosa499 ปีที่แล้ว

    This is amazing! Thank you!

  • @JLa-lw6pe
    @JLa-lw6pe 3 หลายเดือนก่อน

    Keep getting an error message when trying to attach file using this code above it is not reading the drive the file is in.......I am trying to attach an excel file, the file path is correct but keep getting an saying "Cannot find file. Verify the path and file name are correct". How do I fix this?

  • @SanviPatil2019
    @SanviPatil2019 2 ปีที่แล้ว

    superb.. sir how we can send pay slip without outlook via. SMTP

  • @Srikanth-lb3gl
    @Srikanth-lb3gl 4 หลายเดือนก่อน

    Hi, Could you please share the code, Thanks in Advance

  • @josephkelly4310
    @josephkelly4310 ปีที่แล้ว

    Can I do this on Mac?

  • @rasikajadhav2746
    @rasikajadhav2746 ปีที่แล้ว

    Same can we used in mac???

  • @himanshudaksh6796
    @himanshudaksh6796 2 ปีที่แล้ว

    Hello Sir, can we do this with the recording feature in Macro?

  • @sunnykunche
    @sunnykunche ปีที่แล้ว

    I created new file, when i click send message is coming as Done but email is not going out of Outlook, i enabled Microsoft Outlook object library but still it is not running in outlook

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      any error message?

    • @sunnykunche
      @sunnykunche ปีที่แล้ว

      @@AutomationMadeEasy No error message sir getting message as email sent but emails not going from outlook

  • @ರಘುನಾಥ್ಕೆ
    @ರಘುನಾಥ್ಕೆ ปีที่แล้ว +1

    Sir name part is not working its coming ws how to make it to auto fetch correct name from Customer Name coloum
    Please guide

  • @ರಘುನಾಥ್ಕೆ
    @ರಘುನಾಥ್ಕೆ ปีที่แล้ว

    Sir could you please guide how to delay the mail sending 60 seconds for each mail 🙏

  • @albertodiaz6915
    @albertodiaz6915 ปีที่แล้ว

    Hello! Can you please share with me a copy of the macro so I can customise it. Thanks

  • @mallikarjunamavilla7479
    @mallikarjunamavilla7479 2 ปีที่แล้ว

    hi the code not working me
    it's asking for error 424 Object required

  • @sharmilaramnani1740
    @sharmilaramnani1740 ปีที่แล้ว

    I am getting some error. Can you please guide me... I can mail you the code I have written based on your tutorial...

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      what is the error description?

    • @sharmilaramnani1740
      @sharmilaramnani1740 ปีที่แล้ว

      @@AutomationMadeEasy The code DimObjOutlook As Object is getting highlighted and the error message is Complile error. Statement invalid outside type block.

    • @sharmilaramnani1740
      @sharmilaramnani1740 ปีที่แล้ว

      Would it be possible for you to review my requirement and make the necessary modifications in my file? Naturally for a fee...

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      share your requirements at info@automationandagile.com

    • @sharmilaramnani1740
      @sharmilaramnani1740 ปีที่แล้ว

      @@AutomationMadeEasy Sent...

  • @KamalRaj-nl8jg
    @KamalRaj-nl8jg ปีที่แล้ว

    I get error 438 and error in attachment code line. How to debug it

  • @rodgeri.gaeseb7297
    @rodgeri.gaeseb7297 ปีที่แล้ว

    I am getting an error on line 424 error when setting strMailBody...

  • @deepshah3344
    @deepshah3344 9 หลายเดือนก่อน

    Microsoft Outlook object library is not shown in my list

  • @shalinsharma6662
    @shalinsharma6662 2 ปีที่แล้ว

    Hi, how can we add weblinks in the mail body ? please reply

  • @SunitaKumari-fb6gg
    @SunitaKumari-fb6gg ปีที่แล้ว

    Thanks

  • @sandippatil8588
    @sandippatil8588 ปีที่แล้ว

    I wish to add body table in this

  • @chitreshmhaskar6893
    @chitreshmhaskar6893 2 ปีที่แล้ว

    Sir apki google forms vali coading fail ho gayi coz form shuffle mode pe hai apka video dekh ke same try kiya but getRange not defined show ho raha hai

    • @AutomationMadeEasy
      @AutomationMadeEasy  2 ปีที่แล้ว

      getRange fail hone ka reason hain you are trying to read data from incorrect cell of the sheet. Script will wotk fine on open forms provided it is correctly designed and developed. Maine ek example diya hain but every form is different and will need customization based on the form

  • @benjaminmathew8578
    @benjaminmathew8578 ปีที่แล้ว

    Can you share coding

  • @kwesi_AI
    @kwesi_AI ปีที่แล้ว

    Please how do I add the option to Copy someone in the email

  • @sanjeebmaharjan
    @sanjeebmaharjan ปีที่แล้ว

    If only we could send it from gmail too

    • @AutomationMadeEasy
      @AutomationMadeEasy  ปีที่แล้ว

      yes its certainly possible. Refer below tutorial:
      th-cam.com/video/c7S0-3x9hFw/w-d-xo.html

  • @ayanshetty9023
    @ayanshetty9023 2 ปีที่แล้ว

    Please share your excel file with us