#### Date calc limitations in Excel

```Hi There,

I've encountered a problem in the way that Excel calculates the perio
between two dates. In particular if the first date is the start of th
month and the second date is the last day of the month, Excel assume
that this is an incomplete month. Therefore, if the period is rounde
to complete months Excel will calculate the period as a month short.

For example:

01-Apr-2003 to 31-Mar-2004 = 12 months

However, Excel will calculate this as one day short of 12 months.

Does anyone have a work-around for this?

Thanks,

Eamo

--
Message posted from http://www.ExcelForum.com

```
 0
5/28/2004 3:48:17 PM
excel.misc 78881 articles. 5 followers.

5 Replies
390 Views

Similar Articles

[PageSpeed] 58

```Hi

To Excel, dates are just numbers. If you take 1 away from 3, you get 30 -
just as Excel does. The usual workaround is just to add 1 to each
calculation.

Hope this helps.

--
Andy.

"Eamon >" <<Eamon.16z3mf@excelforum-nospam.com> wrote in message
news:Eamon.16z3mf@excelforum-nospam.com...
> Hi There,
>
> I've encountered a problem in the way that Excel calculates the period
> between two dates. In particular if the first date is the start of the
> month and the second date is the last day of the month, Excel assumes
> that this is an incomplete month. Therefore, if the period is rounded
> to complete months Excel will calculate the period as a month short.
>
> For example:
>
> 01-Apr-2003 to 31-Mar-2004 = 12 months
>
> However, Excel will calculate this as one day short of 12 months.
>
> Does anyone have a work-around for this?
>
> Thanks,
>
> Eamon
>
>
> ---
> Message posted from http://www.ExcelForum.com/
>

```
 0
andyb1 (494)
5/28/2004 3:58:05 PM
```Hi Eamon!

Excel is counting fence panels. You're counting fence posts.

Example:
A1: 1-Apr-2003
B1: 31-Mar-2004
=DATEDIF(A1,B1+1,"y")
Returns 1

--
Regards
Norman Harker MVP (Excel)
Sydney, Australia
njharker@optusnet.com.au

```
 0
njharker (1646)
5/28/2004 3:59:58 PM
```Hi
with what formula are you calculating this?

--
Regards
Frank Kabel
Frankfurt, Germany

> Hi There,
>
> I've encountered a problem in the way that Excel calculates the
period
> between two dates. In particular if the first date is the start of
the
> month and the second date is the last day of the month, Excel assumes
> that this is an incomplete month. Therefore, if the period is rounded
> to complete months Excel will calculate the period as a month short.
>
> For example:
>
> 01-Apr-2003 to 31-Mar-2004 = 12 months
>
> However, Excel will calculate this as one day short of 12 months.
>
> Does anyone have a work-around for this?
>
> Thanks,
>
> Eamon
>
>
> ---
> Message posted from http://www.ExcelForum.com/

```
 0
frank.kabel (11126)
5/28/2004 4:03:34 PM
```Hi Frank,

I'm using the formula

=TRUNC((B1-B2)/365.25*12,0)/12

This allows me to return the period in complete years and months. Thi
works great for all dates except where the dates fall on the first an
last day of the month.

I've already added 1 day (or month) where necessary, but I was reall
searching for an all-inclusive remedy! Maybe I'm being too hopeful?

Thanks,

Eamo

--
Message posted from http://www.ExcelForum.com

```
 0
5/28/2004 4:21:59 PM
```Hi
use DATEDIF for this. See:
http://www.cpearson.com/excel/datedif.htm

--
Regards
Frank Kabel
Frankfurt, Germany

> Hi Frank,
>
> I'm using the formula
>
> =TRUNC((B1-B2)/365.25*12,0)/12
>
> This allows me to return the period in complete years and months.
This
> works great for all dates except where the dates fall on the first
and
> last day of the month.
>
> I've already added 1 day (or month) where necessary, but I was really
> searching for an all-inclusive remedy! Maybe I'm being too hopeful?
>
> Thanks,
>
> Eamon
>
>
> ---
> Message posted from http://www.ExcelForum.com/

```
 0
frank.kabel (11126)
5/28/2004 4:29:07 PM

Similar Artilces:

Excel 2002 print problem
Excel 2002 rearanges cells and rows when iI print deos any one know why and how to fix it these are spread sheets created in other computers I am using a tablet pc ...

House account limits, and another Run time error
I need unlimited \$\$ accounts for in house charges that are tender types, not for customers that we create for mailorders and such. These house charges are meant for other departments within our company. Ideas? Run time error '-2147467259(80004005)'. [DBNETLIB][connetionWrite (wrapperWrite()).] General newtork error. Check your network documentation. ---what could this mean??--- You'd want to be careful of accounting ramifications, but you can do this: 1. Set up a new account type, say "InHouse". (Database > Account Types > New -- settings within may not...

filter by date and action
I have a table with three columns: Name Date Action Fred Today this Fred Today this Fred Today that Wilma Today this I want to sort by name and by date, but only if 'this' was done more than once on the same day, and not if 'that' was done on the same day,They have to perform this more than once, and they cannot have performed that on the same day. If not in excel, mssql maybe? Thanks, Harry On Aug 18, 1:53=A0pm, Harry <hamac...@gmail.com> wrote: > I have a table with three co...

How do I reposition a column on an excel spreadsheet
I want to move column J with data over to become column B. How to do this? Select Col J. Right click>Cut Select ColB. Right click>Insert Cut Cells -- Jacob "JonesALewis" wrote: > I want to move column J with data over to become column B. How to do this? Jacob's was is a good way of doing it. Here is another. Highlight the column. Hold down the Shift Key and Drag it to column B and Drop it. Note that when you are holding the shift key and drag you get an I Beam to indicate where you are about to drop the row. If you do not hold down the Shift key...

Calculate Years/Months Between Dates and then Average
We are using the formula =DATEDIF(A1,NOW(),"y") & "." & DATEDIF(A1,NOW(),"ym") to calculate the years and months from an employee hire date. Is there an easy way to average the years and months for a group of employees with the results of that formula? You could use: =AVERAGE(A1:A10*1) Array-entered, meaning press ctrl-shift-enter. But you could also just change your current formula to: =1*(DATEDIF(A1,NOW(),"y") & "." & DATEDIF(A1,NOW(),"ym")) Then just use: =AVERAGE(A1:A10) which is *not* array-entered. ...

Our accounting department needs/wants to have all RMS SO reporting by business date opposed to transaction date. Usually these are the same unless you have sales and batches that close after midnight. For our store I would like to set 3 a.m. as the business day closing time. So when I run any type of reports I would like to get the information for a business date (range) starting at 3 a.m. till 3 a.m. the next day. I guess I could accomplish this by subtracting 3 hours from all the transaction (date and) times but I would have to do this for every single report which would be a lot of ...

Post Dated Checks
I had to prepare some post dated checks and we did not have fiscal periods set up yet to match the dates of the checks. Currently the check batches are waiting to be posted. What is the best way to handle post dated checks? If I create new fiscal years to match these dates, I will end up having 4 Open years. Is this the only way to do it? You can manage post dated checks in Microsoft Dynamics GP with the Payment Document Management module available on the Feature Pack 1 DVD image. For more info, take a look at MVP Mohammad Daoud's post on the subject at: https://communit...

Automation Excel too slow..
I like to get some help from Excel-automation-experienced guys: I started from article http://support.microsoft.com/kb/186122/ which shows how to open, read some contents, close excel file in MFC. I copied codes from article and pasted to OnInitDialog() with slight modification. Every time I click button, it opens, reads, displays Excel file contents in poped-up dialog, then when OK button clicked, it closes Excel file and application. It seems works and I have two problems here(I am using VC++6.0, win2000, excel 2000): 1. Too slow.. about 8 seconds after button clicked, 'Server Busy'...

Remove "Date: Yesterday" or "Date: Monday" from Outlook Inbox?
Outlook mail inbox now has headers that tell you what day the the email was sent. I find this visually annoying. Each emailalready has the time and day it was sent. I don't need the daily titles in the midst of the list of emails. How do I make them go away? I think you are talking about OL 2003 & the Arrange in Groups setting. Change it in View, Arrange by, uncheck Show in Groups. "silky" wrote: > Outlook mail inbox now has headers that tell you what day the the email was > sent. I find this visually annoying. Each emailalready has the time and day >...

Help with an Excel formula
Hey, wondering if anyone can help me with a formula i need it to recognise that if the answer is negative it needs to be red. I think i need an if/then statement but do not know how?? Eg say the formula was just simply = F15-G15 then i need something to say if this anwer is negative then highlight red any help would be great thanks Create a custom format. Right click on the cell, choose Format Cells... On the Number tab, choose Custom. Try one of the formats with [Red] in it. If you like it, great. If not, you can create your own format. The rule is anythi...

How to sort by name then date?
I would like to look through all the emails to a particular person. If I click on the "To" column I can see all the emails to a particular person (actually there is a problem with that which I will mention next) but they seem to be in random order. Is there a way to have them sorted by date? (i.e. by name first, then by date). Actually, sorting on the "To" column does not get all the emails sent to a given email address. Because Outlook uses the "display as" field. It will often give different "display as" names to the same email address. C...

Excel price history import...
Hello, I have Money 2004 Deluxe and an excel file with a mutual fund price history. Is there a way to import the price history straight from the excel file avoiding manual imput??? (online update doesn't work because the mutual fund I'm dealing with is not available) Thanks, Lionel Modi ...

Is there an interpolation-function in Excel to read a chart more .
Your question appears to be incomplete. It is usually best to elaborate in the body of your post. The worksheet functions FORECAST(), TREND(), and GROWTH() can be used to interpolate linear, multiple linear (including polynomial) and exponential regressions. Jerry ...

Non Calendar Year FSA Deduction limits
Hello Thank you for using news groups! I do not see an easy way to handle this as well. In payroll it is always on a calendar year, so the YTD amounts and limits are always from DEC-JAN The only other options I can think of is periodically change the Maximum deduction per year. For example keep it at \$3000 to take out January/February/March then increase it to \$6000 when OCT/NOV/DEC. You can go to (Tools | Setup | Payroll | Deduction) to adjust that max, you can choose yes to roll it down to all employees that have this. I am not tax accountant so I do not know the rules for the W-...

document user storage limit settings
Is there a way (util, vbs, etc) to document storage limit settings for individual users without having to manually go through AD? Once the documentation is done, is there a way to reset a group (OU or security group) to default storage limit settings? Background: We've been on Exch 5.5 for years and have just migrated to Exch 2003 Ent. Many of the 400+ users have individual storage limits but I would like to use the store limits are the primary limiter. Any suggestions would greatly be appreciated. Thanks, -- David MCSE 4, Network +, A+ "DavidTN" <DavidTN@discussion...

Excel puts a 1 at the end of my filename
Whenever I open any Excel file, Excel automatically puts a 1 at the end of the filename. So for instance I'm trying to open xxx.xls I get xxx1.xls. And I have noticed that since this started happening I only get the "save as" option when I go to save the file. What could be causing this? Are you sure the filename includes the .xls extension? If it really doesn't, how are you opening the workbook? If the name of the file is: xxx.XLT (with a T), then the file is a template file. If you are opening a *.xlt file in windows explorer, then windows figures that you want to...

strange date format problem
Hi, I downloaded some data on excel using Bloomberg. One column has dates and the other has numbers. Dates appear as 01/01/1980 format which I want in Jan-80 format. I have changed the format cell properties but it still appears as 01/01/1980. I have to goto individual cell and press F2 <enter> so see the effect. Dont know why? I cant even copy paste format after that .... TIA/amag I am not sure, but is your workbook set to Auto-Recalculate? Try pushing <F9> to do a manual re-calculation, see if that changes the formats. If it does, go to Tools (on the menu bar), Options, Ca...

how do i add a logo to an excel 2003 invoice template?
In Office 2000 you were able to add a logo in the left upper corner of an invoice when customizing. In Office 2003 it seems that you cannot. PLEASE HELP! Thank You I don't know what special facility Office 2000 had, but can't you just paste a bitmap onto the Excel cell? - DH ...

Concatenate including a date so that the date appears as a date
When I try to join the contents of several cells, one of which is a date and time obtained from =now(), the date and time part appears as a number. How can I make it appear as a date and time? I have tried changing the cell formats - probably there is a combination that works but I haven't found it. I also tried copying the original date cell to another cell and changing the latter cell's format and concatenating using that latter cell, but still no success. Use the TEXT function. For example, =TEXT(NOW(),"mmmm d, yyyy") would give January 6, 2010 "dd...

if statement with dates #2
I would like to have a statement like: IF(a1>0,1/1/2004) with 1/1/2004 beint a date. EXCEL is interpreting 1/1/2004 as an arithmetic statement and giving me the result of the arithemtic. I could put in the numeric offste for the date and write IF(a1>0,37987), formatting the cell as a date, but this seems awkward. What else can I do? TIA, Sanford ...

Counting Dates?
=COUNTIF(A1:A100,"<" & NOW()) This works good for specific cells. I have a similar question. How would I do the same thing given that: 1) You only have a starting date 2) Your only wanting to count work days (in this case 4 day/wk) up to NOW() Thank you for all your help. Aviator On Thu, 6 Jan 2005 12:53:03 -0800, "Aviator" <Aviator@discussions.microsoft.com> wrote: >=COUNTIF(A1:A100,"<" & NOW()) > >This works good for specific cells. I have a similar question. > >How would I do the same thing given that: >1) You only ha...

Count Unique Cells, within a date range (dates stored in separate column).
Hello All: I am attempting to create a formula that will count the number of unique cells (alpha-numeric) in an entire column (no set length, so ex: "\$B:\$B"). This count will be based on a date range (Between 2 dates). The dates are stored in another column (Ex: "\$A:\$A"). The following is an example of the cells. Dates PO_Num 1/2/2010 A123456 1/3/2010 B453453 2/2/2010 A123456 3/4/2010 C2342F3K 4/3/2010 123456 I would like to know a formula that can count the number of different PO's based on a given date range. Please help me if you...

Emailing through Outook from Excel
Hi I run Outlook 20003, Excel 2000 and WinXP I have a spreasheet that contains a macro that allows me to send the Excel workbook directly to a group of email addresses. When this macro is run, it puts an email into my Outlook OUTBOX. The problem I have is that I then have to open Outlook and go into my OUTBOX and press the send/receive button before this email is sent. Is there a way that when an email goes into my outbox like this that I can let Outlook know just to send it without me actually having to go into Outlook and press the send/recieve button? Thanks John Calder Outloo...

An expression for dates from and to
I am trying to create an expression to select items from a date field falling from a certain date to a certain date. I am obviously missing something in my expression. The field name is DateComplete. How can I set up this expression to pull date from a certain date to a certain date? -- Ronnie Hi Ronnie, An example of the SQL would be: SELECT * FROM [TABLE NAME] WHERE DateComplete Between #1/1/2006# And #1/1/2007# ; On May 23, 3:52 pm, Ronnie <Ron...@discussions.microsoft.com> wrote: > I am trying to create an expression to select items from a date field falling > from a...

FoxPro Files Too Large for Excel?
I am attempting to open .DBF files in Excel that contain over 300,000 Rows of information. Excel will only display 65,536 Rows. When I open the document in Notepad, I can view the missing information, but all the formatting is gone. Is there a way to open up the large document to spill over onto multiple spreadsheets? I would appreciate any suggestions, even recommendations for other software to use for this situation. xl cannot exceed 65,536 rows, Quattro can take more though. May be worth looking to see if you really need to bring the data int xl as the alternatives are Access and ru...