Date - stay static

itsgrady

Board Regular
Joined
Sep 11, 2022
Messages
132
Office Version
  1. 2021
Platform
  1. Windows
  2. MacOS
I have a date field with today() that returns current date. I need for it to remain date when shift starts. The shift is from 6PM to 6AM. When form is being updated throughout the shift, the date changes to the next after 12 midnight. Is there a way to enter date automatically without it being updated after 12 midnight?
 

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).
Try pressing Ctrl + ;
If you want it to remain the same date via formula then you can't do it (unless you amend your iterations settings, which I won't recommend), you'll need VBA.
 
Upvote 0
Hi, assuming that after 6AM you want it to update to the current date again, you could try:

Excel Formula:
=TODAY()-(MOD(NOW(),1)<TIME(6,0,0))
 
Upvote 0
Solution
Try pressing Ctrl + ;
If you want it to remain the same date via formula then you can't do it (unless you amend your iterations settings, which I won't recommend), you'll need VBA.
Thanks for your reply.
 
Upvote 0
Hi, assuming that after 6AM you want it to update to the current date again, you could try:

Excel Formula:
=TODAY()-(MOD(NOW(),1)<TIME(6,0,0))
The formula is working great. Thanks for your help!
 
Upvote 0

Forum statistics

Threads
1,223,630
Messages
6,173,454
Members
452,514
Latest member
cjkelly15

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