# Data Validity

Next question. In data validity can I enter a formula?

So I want sum($E25$:$E$32)<=$E$34 If input is more than allowed in E34 they will get error alert “you may not assign more than allowed in cell E 34”

Can I control data validity in calc with a formula?

When I open data validity I see the formula crossed over from what was built in excel but it isn’t working and is grey so I can’t figure out how to edit it

Right now, for example say if E 34 is 6. If I put 5 in cell E 25 and 2 in cell E 26 it allows this to happen. No error.

The error only pops up if I were to put say 8 in one single cell but not if the total is greater than E34.

edit retag close merge delete

Sort by » oldest newest most voted

Please note: The Validity feture is a very weak means to ensure the restrictions you aim at. However: Didn't you try? For bounds and for cell ranges as well you can use formulae.

(Editing:)
See this demo.

more

Didn’t work. I’m hoping for a solution. This is a common errror so having the system prevent it would be great.

( 2018-01-14 00:53:31 +0200 )edit

It worked for me. Why shouldn't it work for you?
Quoting @Rockerdo: "This is a common errror...". What so you mean by this? What error message did you get?
Did you note meanwhile that the comparison with "<=" and "input is more than allowed" don't match?

( 2018-01-14 01:07:57 +0200 )edit

I finally got it. Sorry I’m so used to excel formulas it takes me a while to figure out the differences.

( 2018-01-14 01:20:36 +0200 )edit