Results 1 to 8 of 8

How to check adjacent cell for value and display error message for certain conditions

Threaded View

  1. #1
    Forum Contributor
    Join Date
    08-04-2010
    Location
    Adelaide, Australia
    MS-Off Ver
    Office 365
    Posts
    176

    How to check adjacent cell for value and display error message for certain conditions

    Hi all,

    as roster coordinator for my workplace, I usually handle all the allocation of overtime when it arises. I was on vacation just recently, however, and a couple of other supervisors incorrectly allocated some overtime. To get around that human error, I've been trying to code something that would check cell values and throw up a message box if certain conditions were met. I've been trying a sheet change event using offset but without much luck so I'm hoping someone can point me in the right direction. Basically I'm trying to achieve this...

    Range of cells is A4 to AA42

    If a user enters a value of "L" or "OL" into the sheet, it should check the cell immediately to the left, and if it finds a value of "N" or "ON', throw up the message box. Conversely, if a user enters "N' or "ON' into a cell, it should check the cell immediately to the right for a value of "L" or "OL", and if found, throw up a message box.

    Thanks in advance for any suggestions,

    AJ
    Last edited by ScotyB; 05-01-2017 at 07:59 PM. Reason: to mark as solved
    Always grateful for the help here - thanks.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Display error message if cell has no value
    By callum91 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-20-2015, 10:40 AM
  2. Display ActiveCell and Adjacent Cell Values in message Box
    By Tellm in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-27-2015, 12:16 PM
  3. Replies: 3
    Last Post: 06-19-2014, 06:07 PM
  4. Muliple Conditions to Check in a table to display value in a cell
    By Kapil Gosain in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 04-10-2013, 03:36 AM
  5. VBA - Check 3 rows if blank and display text in one of them in adjacent cell
    By guitalex in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 02-17-2012, 09:32 AM
  6. Replies: 2
    Last Post: 12-18-2009, 05:20 PM
  7. [SOLVED] How to display a blank cell with no error message
    By Juco in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 01-31-2005, 05:06 AM

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