Only allow certain decimal numbers?

merstevens

New Member
Joined
Sep 27, 2023
Messages
2
Office Version
  1. 365
Platform
  1. Windows
I am trying to create a spreadsheet that only allows people to enter either whole numbers, or numbers ending in the decimals .25, .5, or .75. This is a spreadsheet that goes out blank, and gets sent back to me with information entered and if the correct decimal intervals aren't used, I have to recalculate them myself so I'm trying to build a spreadsheet that either doesn't allow the other decimal intervals, or that rounds them up automatically, and I can't figure out how to do it. Any suggestions? I thought maybe a custom data validation, but I can't figure out what the formula for that would be.

The spreadsheet is a timesheet that uses hour totals, not times, if that helps at all. In the image, I would need these limits to start in cell F12.
 

Attachments

  • new timesheet - forum question pic.PNG
    new timesheet - forum question pic.PNG
    18.1 KB · Views: 16

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.
from what it sounds like, this should work for you. it allows people to put in any number, but ti rounds each number up to the nearest .25
-------------------------
Book1
FGHIJK
30.750.680.550.252.5
Sheet1
Cell Formulas
RangeFormula
K3K3=SUM(CEILING(F3:I3,0.25))
 
Upvote 0
Or if you want to use data validation for say cell A1 you can use this custom formula:
Excel Formula:
=OR(MOD($A1,1)=0,MOD($A1,1)=0.25,MOD($A1,1)=0.5,MOD($A1,1)=0.75)
 
Upvote 0
Solution
You can use data validation with a custom formula of
Excel Formula:
=F12=MROUND(F12,0.25)
 
Upvote 0
Did you try the formula I suggested?
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,175
Members
453,021
Latest member
Justyna P

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