How do i put a limit on an entry in a cell?

J

John

Hi, I am trying to organise a timesheet and there is one thing that I can't
get past. How do I put a limit on a number entered into a cell? My example
is, I want the "hours carried forward" cell to stop at 20. I would like this
to just apply to one cell but on all worksheets. For instance, if I have 21
hours flexi accumulated in week one and I want the flexi carried over to week
two (separate worksheet), instead of it showing 21 I would like it to remain
at 20. However, I still want the cells to allow numbers lower than 20. Can
anyone help me out please? Thanks
 
C

Chip Pearson

The MIN function will return the lesser of two numbers. E.g.,

=MIN(A10,20)

will return A10 if it is less than or equal to 20 and will return 20 if A10
is greater than 20.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting
www.cpearson.com
(email on the web site)
 
J

John

Thanks for your promt help. Much appreciated.

Chip Pearson said:
The MIN function will return the lesser of two numbers. E.g.,

=MIN(A10,20)

will return A10 if it is less than or equal to 20 and will return 20 if A10
is greater than 20.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting
www.cpearson.com
(email on the web site)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top