Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 12
Default Days of a given month

Hi!

Can anybody help me?
I need to get the number of days on a given month-year. (ie Jan-07 = 31
days, etc)

Is there an easy way to get it?

Thnx
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default Days of a given month

Put a date in a1 and this will return the days in the month od that date

=DAY(DATE(YEAR(A1),MONTH(A1)+1,1)-1)

Mike

"Jepane" wrote:

Hi!

Can anybody help me?
I need to get the number of days on a given month-year. (ie Jan-07 = 31
days, etc)

Is there an easy way to get it?

Thnx

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,089
Default Days of a given month

If the date is in cell D6, the following formula in E6 formatted as "dd"
will give you the number of days.

=DATE(YEAR(D6),MONTH(D6)+1,0)

It would need to be a "proper date", for example, 16/02/2007. This would
display as 28

Regards

Trevor


"Jepane" wrote in message
...
Hi!

Can anybody help me?
I need to get the number of days on a given month-year. (ie Jan-07 = 31
days, etc)

Is there an easy way to get it?

Thnx



  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,202
Default Days of a given month

Can anybody help me?
I need to get the number of days on a given month-year. (ie Jan-07 = 31
days, etc)

Is there an easy way to get it?


=DAY(DATE(YearNumber,MonthNumber+1,0))

Put the year number in the first argument, the month number PLUS one in the
second argument and zero in the third argument.

Rick

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 12
Default Days of a given month

Thanx

"Mike H" wrote:

Put a date in a1 and this will return the days in the month od that date

=DAY(DATE(YEAR(A1),MONTH(A1)+1,1)-1)

Mike

"Jepane" wrote:

Hi!

Can anybody help me?
I need to get the number of days on a given month-year. (ie Jan-07 = 31
days, etc)

Is there an easy way to get it?

Thnx



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default Days of a given month

One suggestion
=WORKDAY(A1,15)

in B1

Mike


"Jepane" wrote:

Hi!

Can anybody help me?
I need to get the number of days on a given month-year. (ie Jan-07 = 31
days, etc)

Is there an easy way to get it?

Thnx

  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,202
Default Days of a given month

One suggestion
=WORKDAY(A1,15)


To the newsgroup administrators:

Please move this response down one thread.

Thank you,

Rick

<g
  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,718
Default Days of a given month

Required Analysis ToolPak add-ins

=DAY(EOMONTH(A1,0))


"Jepane" wrote:

Hi!

Can anybody help me?
I need to get the number of days on a given month-year. (ie Jan-07 = 31
days, etc)

Is there an easy way to get it?

Thnx

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Days per month for calculating storage days Bart Excel Worksheet Functions 3 January 31st 07 06:40 PM
function to fill all days of month to end of month Monique Excel Worksheet Functions 11 May 1st 06 07:39 PM
function to fill all days of month to end of month YaHootie Excel Worksheet Functions 10 May 1st 06 06:01 AM
Dates - Several Days In a month to month only Andy_Pimp Excel Discussion (Misc queries) 1 February 28th 06 11:11 AM
How to Set a fix # of days per month iboock Excel Worksheet Functions 0 November 3rd 04 06:53 AM


All times are GMT +1. The time now is 02:07 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"