?
Solved

Excel Validation function

Posted on 2011-02-28
6
Medium Priority
?
384 Views
Last Modified: 2012-05-11
In my Example I have a list of items on a separate sheet.  I have a data validation rule that says the items must be selected from my list.  I want to be able to run a formula in my Excel sheet that lets me know if the data in the cell is valid.  I cannot use any VBA code to do this because I have a new requirement  to not use any macros in this worksheet.  

Here is the VBA function I had written.

Public Function ISVALID(ByVal Target As Range) As Boolean
    ISVALID = Target.Validation.Value
End Function

However, I need a way to do this using the current Excel formulas.  Any help would be appreciated.
0
Comment
Question by:busapps
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 5

Expert Comment

by:roger_karam
ID: 34998184
Do you have a sample sheet with what you are looking for? What is your validation rule?

-RK
0
 
LVL 6

Expert Comment

by:Eric Zwiekhorst
ID: 34998250
I do not understand the need for this check.

If you have as validation a list the value you enter can not be other then in this list.

if you use the dropdown it is always valid.
If you type you can't type anything else then in the list so it is valid to.
Only if you want to prevent a blank, and that is a easy check..



Kind regards


Eric
0
 
LVL 85

Expert Comment

by:Rory Archibald
ID: 34998471
There is an option on the Data Validation menu to circle invalid data. No formulas or VBA required. :)
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 85

Expert Comment

by:Rory Archibald
ID: 34998497
PS It's on the Formula Auditing toolbar pre 2007.
0
 
LVL 81

Accepted Solution

by:
zorvek (Kevin Jones) earned 2000 total points
ID: 34998592
Use the MATCH function:

   =NOT(ISNA(MATCH(Target,ValidationList,0)))

Kevin
0
 
LVL 1

Author Closing Comment

by:busapps
ID: 35012123
I ended up using the following formula into conditional formatting:  

=AND(ISNA(MATCH(Target, DestinationList, 0)), LEN(Target)>0)

Thanks to all for the responses.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This Article briefly covers methods of calculating the NPV and IRR variants in Excel as well as the limitations in calculating and interpreting IRR results. Paraphrasing Richard Shockley, author of my favourite finance reference tex…
Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question