+ Reply to Thread
Results 1 to 2 of 2

Email alert based on condition, VBA

  1. #1
    Registered User
    Join Date
    01-09-2013
    Location
    Medias, Romania
    MS-Off Ver
    Excel 2011
    Posts
    6

    Email alert based on condition, VBA

    Hello all, I am trying to send an email with all things I must change to my car. In row A I have the condition (yes or no).
    So if cell value in row A (I set range A2:A4 for now) is "yes" then the code sends an email to a specific mailbox with text from cell B2.
    The excel looks like this:
    A B
    Implement change Change description
    yes change tires
    no change oil
    yes change filters

    What I did so far:

    Please Login or Register  to view this content.
    the code as it is only writes me an email with only text from cell B2 -> Email_Body = Range("B2")
    My blocking point is, I want all values from column B, not just one value, any suggestions what should I put instead Email_Body = Range("B2"),

    Thank you.
    Last edited by Ashrak; 06-07-2019 at 05:44 AM. Reason: more accurate request

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,448

    Re: Email alert based on condition, VBA

    Administrative Note:

    Welcome to the forum.

    We would very much like to help you with your query, however you need to include code tags around your code.

    Please take a moment to add the tags. Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, and it also maintains VBA formatting.

    Click on Edit to open your post, then highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here

    (Note: this change is not optional. No help to be offered until this moderation request has been fulfilled.)

+ 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. Email alert not firing with created macro even though the condition is satisfied.
    By sarat47 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 01-13-2017, 07:23 PM
  2. rule to send an email alert to another email address
    By wayneg in forum Outlook Formatting & Functions
    Replies: 1
    Last Post: 02-08-2016, 06:15 PM
  3. Looking to alert/email certain people on certain dates based on excel data
    By Wooodd in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-29-2015, 08:52 AM
  4. [SOLVED] Creating an alert based on a surpassed condition
    By clabhart in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 06-19-2014, 03:43 PM
  5. Replies: 0
    Last Post: 10-10-2013, 05:14 AM
  6. Code How to show alert messages with the IF condition based on other cell value
    By herukuncahyono in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-14-2013, 09:51 PM
  7. [SOLVED] triggering an email alert from within a spreadsheet based upon a d
    By just-curious---george in forum Excel General
    Replies: 0
    Last Post: 03-23-2006, 09:45 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