+ Reply to Thread
Results 1 to 4 of 4

Multiple criteria validation in multiple cells

  1. #1
    Registered User
    Join Date
    05-15-2014
    MS-Off Ver
    Excel 2010
    Posts
    25

    Multiple criteria validation in multiple cells

    Hi Everyone,

    I've got multiple cells with strings of text that look like the following:

    07000178CA39DN8000000000 20150111 050099999999
    07000178CA39EN5600000000 20150111 020099999999
    07000357CA39DN8000000000 20151115 000099999999
    07000357CA39EN5600000000 20151115 000099999999


    The first 8 characters of the string correspond to an employee, and there are multiple lines for every single employee. Keeping that in mind, for every different employee in the list, I'm trying to validate that the following:
    1. Check the string that contains "DN80" as characters 13 to 16 for the value contained in characters 35 and 36
    2. If the value of characters 35 and 36 is higher than "04", and this is where it gets tricky, I need to go check in another line (that contains "EN56" as chr 13 to 16), but for the same employee (8 first characters), if the value of chr 35 and 36 is "02". If it's not, I need to turn it in red font.

    My main issue here is figuring out how to validate values in a different cell than the one with the first criteria, while remaining in the same employee (8 first digits).

    Do you think it can be done?

    Thanks a lot!

  2. #2
    Forum Expert
    Join Date
    08-16-2015
    Location
    Antwerpen, Belgium
    MS-Off Ver
    2007-2016
    Posts
    2,380

    Re: Multiple criteria validation in multiple cells

    sheet is selected and the data is in column A
    this can do


    Please Login or Register  to view this content.
    Kind regards
    Leo

  3. #3
    Registered User
    Join Date
    05-15-2014
    MS-Off Ver
    Excel 2010
    Posts
    25

    Re: Multiple criteria validation in multiple cells

    Thanks for this, it works but I still get a Type Mismatch Error on the following line:

    If Val(Mid(Range("A" & r), 35, 2)) <> 2 Then

    Any Idea why??

  4. #4
    Forum Expert
    Join Date
    08-16-2015
    Location
    Antwerpen, Belgium
    MS-Off Ver
    2007-2016
    Posts
    2,380

    Re: Multiple criteria validation in multiple cells

    can you poste the file ?


    Kind regards
    Leo

+ 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. Replies: 2
    Last Post: 05-26-2015, 07:29 PM
  2. SUM multiple cells based on multiple cell criteria,not a range
    By georgiepod in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 05-01-2015, 01:10 PM
  3. Multiple cells, multiple sheets, multiple criteria matching
    By Drudnits1 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 12-17-2014, 12:12 PM
  4. Count number of Rows with multiple criteria (multiple valued cells)
    By garog in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 03-09-2014, 01:33 PM
  5. Populating fields in multiple cells based on criteria in multiple columns
    By excelalways in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-28-2014, 08:17 AM
  6. Replies: 1
    Last Post: 12-25-2012, 05:32 PM
  7. Replies: 0
    Last Post: 12-12-2011, 07:27 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