My spreadsheet is to show me how many days active a certain field has been.
For this I am trying to find a formula which will automatically take the entered date from one cell and deduct it from "todays" date.
As an example I have used =DATEVALUE("22/04/2017")-TODAY() - and although this works, i am unable to drag the formula down into other cells, to auto populate when a date has been entered/ amended. I'm having to enter the formula above every time, and if the date changes, as an example from the 22/04/2017 to the 20/04/2017, I would have to manually amend the formula too. How can I get it just pick up the date in that particular cell and deduct "today" from it?
Sorry if i'm rambling, I just don't know if I'm explaining myself properly.
Thank you
Typically, 'how many days active a certain field has been' would be a positive number (i.e. the number of days). Reverse the subtrahend and minuend to get a positive integer like this,
=today()-a3
To avoid getting 5/15/2017 or 42,870 as the result when A3 is blank, check to see if there is something in A3 before attempting subtraction.
=if(len(a3), today()-a3, text(,))
Related
If A1 contained the number 5 and A2 contain the date 7/1/23 when we reached the date of 7/1/23 I want to delete the number 5 in cell A1. Can anyone assist with a simple formula for this? Thank you!
Hey there!
What you want to do within the same cell as the value 5 may require some more skilled coding that allows the cell to hold data and a formula that updates itself. However I can recommend another way that achieves what you want but also retains some history.
The left set is what your result would look like if the date is older than todays date. The right being if todays date has not reached the date you specified.
Before row contains the points that would currently exist, while after would contain the points after the date affects the "drop off" you would like.
Then an If statement just compares whether todays date is older/same/or newer than the target date. (To make this formula more dynamic, you can replace B5 with "today()")
=IF(B5>=B3,"",B1)
or
=IF(TODAY()>=B3,"",B1)
Hope this helps!
What it should look like:
I know this is a simple question, but, what I mean is how do you copy a cell, but when that cell changes, it doesn't affect the copy.
To make it a bit easier to understand, If I had A1 that said "Hi", and I wanted A2to say "Hi" also, I would put =A1. However, if I changed A1, it would change A2 along with it, and that is what I don't want.
I am asking this as I have a formula that says that something is so and so weeks overdue, but when a checkbox is ticked, the weeks counter stops and doesn't add any more.
Here is what I mean and the paragraph underneath states what it means and what I need from it.
The cell that says "13/02/2019" is =TODAY() and the cell that says "06/02/2019" is a date I manually entered. The problem I have is that if I came back in 1 week, it would say "Handed in late by 2 weeks." and that is what I want to prevent. However, I only want this =TODAY() to freeze when that check box is ticked.
Today() reports today's date and it will always update to the current date. Today() is a volatile function that will recalculate on every worksheet change, even cells entirely unrelated to the function. Formulas referencing a cell containing Today() will also update to reflect the current date like you are experiencing now.
You appear to be looking for a process that will snapshot the date at the time of an action (checking a box). If you want it to be a formula, you will need to input the date of return as well and create a formula comparing the difference between to two inputs. There is already a shortcut to insert today's date in a non-formula method: Select the cell and press Control + ; (semi-colon). A simple formula that references the difference between the check-out and check-in dates on a per line basis with rounding and concatenate functions, should accomplish the described purpose.
A1 = (Checkout date)
B1 = (Return Date)
C1 =IF(ROUNDUP((B1-A1)/7,0)=1,CONCATENATE(ROUNDUP((B1-A1)/7,0)," Week"),CONCATENATE(ROUNDUP((B1-A1)/7,0)," Weeks"))
This function checks the difference between A and B, divides by 7 to get number of weeks, rounds it up to a whole number, and checks if the number of weeks is 1 or not. If it is one the text will say " week" otherwise it will say " weeks". This also avoids using a volatile function which in larger projects would cause incessant and potentially resource demanding calculating.
I'm trying to calculate the time between the dates , at the beginning the formula
was working fine but I've noticed that it does not work when the date is different
For example , I have the following information on cell A1: 09/15/2016 10:00 AM
On Cell B2 I have: 09/16/2016 10:00 AM
The formula is just B2-A1 but instead of giving me a result of 24 hours is just giving me 0 . I believe the formula is not recognizing that these are 2 different days and is just doing 10-10
Any idea how to fix this ?
I was able to get the result 24 by setting a custom format of [h] (you will have to type it into the 'Type:' box) on cell C1 while using the formula =B1-A1
Excel Reference
'Format Cells' view
The problem with just using =B1-A1 is that if either or both of those cells is not populated then you will get weird numbers in C1. You may want to make C1 display as a blank cell unless both boxes are populated, try something like this =IF(OR(ISBLANK(A1),ISBLANK(B1)),"",B1-A1)
The reason for the weird numbers is that Excel calculates time based on a predefined decimal system that indexes time starting at like 1/1/1900 or something like that. So when manipulating or calculating time, that is something that you always have to keep in the back of your mind.
Hope this helps.
Formation the destination cell to will do but since you have date and time combined it will show as 1 calendar day difference 0 only means that 12 am after the 1 day difference, I know it does not make any sense but its Excel...
If I was you, on column A, I would add the date, and on Column B, the time.
then just work with the time, as both combined can be tricky
Don't forget to format your cells!! (right click>Format Cells>Time>3/14/12 1:30 PM)
I am not sure if I am just over looking something, because I am still a very newbie to Excel's functions, so here comes the problem :
Lets say that I have A1 cell, and I want to display todays date in another cell whenever the A1 cell isn't empty.
So I came with this :
in another cell :
IF(A1<>"";TODAY();"")
Todays date is 16.8.2015, but when I run TODAY() through a condition like this, the output is : 42232
Why would I get this weird number ?
Maybe I did syntax wrong ? Not sure.. I also tried to make =TODAY() in new cell, that displayed the 16.8.2015, and then I wanted to show that cell through that condition, it threw the "42232" again.
Be sure that the cell format is Date and not General or Number.
The TODAY function returns a serial number which is equivalent to the amount of days since 1/1/1900. That is why you are seeing the number instead of the date.
Select the cell with the number and on the Home tab you can change the format to Date (See Below).
Every date in Excel is represented by a number. For example, the number 1 represents 1/1/1900. Whereas 42232 represents 8/16/2015.
For my Pilots logbook I am trying to be able to make a easy search where you can enter certain criteria and get the amount of landings and time in flight.
For example you could enter the departing airport and it would give you the amount of takeoffs from that airport.
So far I have been able to get the results using the COUNTIFSfunction.
Trying to add a field, where you can enter a year and it would only count the occurrences in that year is giving me a hard time!
The date is in the following format: dd.mm.yyyy. The year to search for would be entered in a cell (yyyy).
Just adding it to the COUNTIFSobviously doesn't work. I know I can get the year out of the date using the YEARfunction, yet I can't figure out a way of including this into the COUNTIF.
Any Ideas?
CODE:
=COUNTIFS(Logbook!F3:F2000,IF(ISBLANK(B30),"*",B30),Logbook!C3:C2000,IF(ISBLANK(C30),"*",C30),Logbook!K3:K2000,IF(ISBLANK(D30),"*",D30),Logbook!L3:L2000,IF(ISBLANK(E30),"*",E30),Logbook!G3:G2000,IF(ISBLANK(F30),"*",F30),Logbook!B2:B2000,B30)
Where B30 is the cell with the year, and B2:B2000 being the cells with the dates.
I also tried to compare by the text (somewhat like RIGHT(Logbook!B2:B2000,4)=B30) but it doesn't do anything but returning a #VALUE error.
Seems like a really good case for PivotTables and slicers... You could even avoid the RIGHT() formula if you format the dates; then you could use the built-in group feature of PivotTables.