+ Reply to Thread
Results 1 to 5 of 5

Multiple warning messages dependent on Cell value

  1. #1
    Registered User
    Join Date
    03-19-2013
    Location
    colchester, england
    MS-Off Ver
    Excel 1997 (work are tight)
    Posts
    3

    Multiple warning messages dependent on Cell value

    Hello, im looking to create a macro that once an entry is put into a cell in column B, it looks up that entry to a list on a new sheet and then dependant on the lookup value i need 1 of 2 warning messages. I need a warning message if the lookup value is "No" and a warning message if the lookup value doesn't bring back a result i.e #N/A. The other potential value is aYes but need no action for that. The warning message box for the 'No' response, will be a simply yes no answer box, with the #n/a warning message box being a simply ok warning message which then goes back on the cell on column B that was originally selected.

    So far i have managed to write the tiny bit of code to enter the v lookup into column c - but am having issues with the multiple warning box. the issues i have had so far have maainly been around multiple warning messages. One message i can do fine (using simliar taks as when adding the vlookup) but then i it errors everytime the #N/A is returned. SO i just need help on having multiple warnig messages if the value in column3 is Yes or N/A. The code i have for the look up is below so any extension to that wold be great

    Thanks in advance for your help

    Please Login or Register  to view this content.
    Last edited by mdimiller; 12-04-2013 at 07:32 AM.

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,595

    Re: Multiple warning messages dependent on Cell value

    You did not post a sample file to test with so, (??):
    Please Login or Register  to view this content.
    Ben Van Johnson

  3. #3
    Registered User
    Join Date
    03-19-2013
    Location
    colchester, england
    MS-Off Ver
    Excel 1997 (work are tight)
    Posts
    3

    Re: Multiple warning messages dependent on Cell value

    Hi Protonleah, thanks for your response, i have now added an attachment with your below code inserted (ammended the ofsett value slightly). The code seems to error at the "Case IsError(LookupReturn" function. I have tried ammending with an IF function and added in = or "", but can't seem to get it to work?

    Thanks in advance
    Attached Files Attached Files

  4. #4
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,595

    Re: Multiple warning messages dependent on Cell value

    Tested ok:
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    03-19-2013
    Location
    colchester, england
    MS-Off Ver
    Excel 1997 (work are tight)
    Posts
    3

    Re: Multiple warning messages dependent on Cell value

    Hi Protonleah - thanks very much for your assistance, that works great.

+ 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. How to use VBA to create two warning messages related to one cell
    By Ledmac in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-05-2013, 05:37 PM
  2. Messages box as warning for changes withing a range
    By mikeyfear in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-23-2008, 03:00 AM
  3. annoying sort warning messages
    By P D Sterling in forum Excel General
    Replies: 1
    Last Post: 07-22-2006, 08:05 AM
  4. Outlook Warning Messages
    By AD108 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-02-2006, 01:10 PM
  5. [SOLVED] Disable cell warning/error messages
    By [email protected] in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-09-2006, 07:35 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