# Thread: Excel - Data Validation syntax

1. ## Excel - Data Validation syntax

In Excel - I have a simple calculation for Cell K25: =((J22*K24)+1) But I want to enforce a rule on the RESULT: Cell K25 must Also be <= C10 Can you help me with the required syntax/formula/Data Validation for this cell? I can’t get my Data Validation error message to appear?

2. You can't do data validation on the result of a formula. However you can do something along the lines of:
Code:
`=IF((J22*K24)+1<C10,(J22*K24)+1,"Result > " & C10)`

3. Thanks for your response! A User (Sergio) within another forum provided me with a very good solution, allowing me to apply it within 'Data Validation' with this syntax: =(\$J\$22*\$K\$24+1) <=C10

Steve

4. I don't think that data validation in cell K25 (what you asked for) will do anything, so I'm guessing you've put that data validation in other cells (J22 and /or K24)?

5. Correct!

6. Steve - the forum rules require you to provide cross-post links if you have posted the same query elsewhere. Please add a link to the solution you were given. If you do this again, please provide the links up front. Thanks.