Is there a way to use data validation on a cell with a formula?

For example, if on cell: A1

I use: Data Validation, Criteria: Allow: Custom, Formula: A1>0

A formula like this will error as an “Invalid value”:

=1/2

But a numerical entry will work:

0.5

How can this be fixed?