Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35
Default Problem with week number/day type formula

Hi

I have a formula to work out the week number and day per month..
C1 ="W"&CEILING(DAY(B1)/7,1)&TEXT(WEEKDAY(B1),"DDD") and B1=TODAY( )

It was working fine but today should be W2Mon and the formula gives W1Mon.

Thanks

Wendy




  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 9,101
Default Problem with week number/day type formula

The code is right. Check the data on you PC to make sure your have the right
date set. You should get 8/7 = 1.333 and the ceiling function should round
up to 2.

"Wendy" wrote:

Hi

I have a formula to work out the week number and day per month..
C1 ="W"&CEILING(DAY(B1)/7,1)&TEXT(WEEKDAY(B1),"DDD") and B1=TODAY( )

It was working fine but today should be W2Mon and the formula gives W1Mon.

Thanks

Wendy





  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,651
Default Problem with week number/day type formula

On Mon, 7 Apr 2008 07:28:03 -0700, Joel wrote:

The code is right. Check the data on you PC to make sure your have the right
date set. You should get 8/7 = 1.333 and the ceiling function should round
up to 2.


From where are you getting the "8"?

--ron
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35
Default Problem with week number/day type formula

Hi Joel

When I do 8/7 my answer is 1.142857. Windows XP, Office 2003 sp2. It is
working ok today!

Wendy




"Joel" wrote in message
...
The code is right. Check the data on you PC to make sure your have the
right
date set. You should get 8/7 = 1.333 and the ceiling function should
round
up to 2.

"Wendy" wrote:

Hi

I have a formula to work out the week number and day per month..
C1 ="W"&CEILING(DAY(B1)/7,1)&TEXT(WEEKDAY(B1),"DDD") and B1=TODAY( )

It was working fine but today should be W2Mon and the formula gives
W1Mon.

Thanks

Wendy







  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,651
Default Problem with week number/day type formula

On Mon, 7 Apr 2008 15:02:43 +0100, "Wendy" wrote:

Hi

I have a formula to work out the week number and day per month..
C1 ="W"&CEILING(DAY(B1)/7,1)&TEXT(WEEKDAY(B1),"DDD") and B1=TODAY( )

It was working fine but today should be W2Mon and the formula gives W1Mon.

Thanks

Wendy




The problem may be that you were not clear in your specifications. For
example, you wrote:

" 2nd Monday is always W2Mon "

Since today is the First Monday of April, then either you will have two W2Mon's
or you need to rethink your specifications.
--ron


  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35
Default Problem with week number/day type formula

Hi Ron

It doesn't matter it is the 1st monday in april it is still the start of
week2.
Can you suggest a way round this to make it work?

Thanks

Wendy

"Ron Rosenfeld" wrote in message
...
On Mon, 7 Apr 2008 15:02:43 +0100, "Wendy" wrote:

Hi

I have a formula to work out the week number and day per month..
C1 ="W"&CEILING(DAY(B1)/7,1)&TEXT(WEEKDAY(B1),"DDD") and B1=TODAY( )

It was working fine but today should be W2Mon and the formula gives W1Mon.

Thanks

Wendy




The problem may be that you were not clear in your specifications. For
example, you wrote:

" 2nd Monday is always W2Mon "

Since today is the First Monday of April, then either you will have two
W2Mon's
or you need to rethink your specifications.
--ron



  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,651
Default Problem with week number/day type formula

On Tue, 8 Apr 2008 11:32:14 +0100, "Wendy" wrote:

Hi Ron

It doesn't matter it is the 1st monday in april it is still the start of
week2.
Can you suggest a way round this to make it work?



With the specifications you have supplied, only by making both yesterday and
next Monday = W2Mon.

You have written:

" 2nd Monday is always W2Mon "

and also:

"It doesn't matter it is the 1st monday in april it is still the start of
week2."

The only way I see to resolve these two statements is to make both yesterday
and next Monday to be W2Mon.

If that is not what you want, then you will have to lay out unambiguous
specifications.
--ron
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
Week number date formula Wendy Excel Discussion (Misc queries) 6 March 20th 08 01:07 PM
Formula to determine number of current records by week Keith Excel Worksheet Functions 6 February 6th 07 04:33 PM
ERROR.TYPE formula problem tuph Excel Worksheet Functions 3 May 25th 06 02:06 AM
Formula for a date's week number in a month (1st, 2nd, etc.) Charles Excel Discussion (Misc queries) 1 March 10th 06 09:06 PM
I need week number in excell from a date, first week must be mini. jPeich Excel Discussion (Misc queries) 4 January 5th 05 01:21 AM


All times are GMT +1. The time now is 05:16 AM.

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

About Us

"It's about Microsoft Excel"