Data Validation on formula result

ad1234

Board Regular
Joined
Jan 16, 2008
Messages
163
Am I right in thinking that the above is not possible? I want an error message to appear if the value in one cell (which is the sum of two others) is above a certain value but a search tells me I won't find a way?
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
Am I right in thinking that the above is not possible? I want an error message to appear if the value in one cell (which is the sum of two others) is above a certain value but a search tells me I won't find a way?

It depends on how you want the error to appear.

This could be done using conditional formatting along with your formula.

Let say you don't want A+B to be greater than 1

=IF(A+B<=1,A+B,"Error")

Will diplay the value if it is less than or equal to 1 and will display "Error" if it is above 1.

You can then use conditional formatting to change the color of the Error value to make it stand out.

ETA:

If you want a no kidding pop-up message, that could be done using VBA. But I don't think it works with standard data validation.
 
Last edited:
Upvote 0
Am I right in thinking that the above is not possible? I want an error message to appear if the value in one cell (which is the sum of two others) is above a certain value but a search tells me I won't find a way?
No, not exactly.
But you can work around it.

YOu put the validation in the Cells that the formula refers to.
A simple example

In C1 you have the formula =A1+B1

You want an error to appear if the value of C1 is above say 100
In A1 and B1, use Data Validation - Custom
=$C1<=100

Hope that helps.
 
Upvote 0
No, not exactly.
But you can work around it.

YOu put the validation in the Cells that the formula refers to.
A simple example

In C1 you have the formula =A1+B1

You want an error to appear if the value of C1 is above say 100
In A1 and B1, use Data Validation - Custom
=$C1<=100

Hope that helps.

I never thought of doing it that way. Had no idea that worked.

I need to add that to my book of tricks. :)
 
Upvote 0

Forum statistics

Threads
1,214,813
Messages
6,121,706
Members
449,048
Latest member
81jamesacct

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top