View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
George B George B is offline
external usenet poster
 
Posts: 9
Default Automatic date entry


Hi Stefi
thanks for the help. I used nos. 1, 2 and 4 all worked great.
Could not get no.3 to work and so used the answer from Ram
thanks
george--
Every decision you make - is a decision about who you are


"Stefi" wrote:

Month No being in A2:

€˛George B€¯ ezt Ć*rta:

I have a spreadsheet where you enter the month. The spreadsheet is organised
into weeks . The weeks run from Sunday to Saturday. I would like to be able
to enter the Month and then have excel enter :-
1.) the no of days in the month in a cell


=DAY(DATE(YEAR(TODAY()),$A$2+1,0))


2.)the opening date of the month in week 1 worksheet


=DATE(YEAR(TODAY()),$A$2,1)

3.) the closing date of the first week of the month (ie the first sat) in
week 1 worksheet


=DATE(YEAR(TODAY()),A2,1+7*1)-WEEKDAY(DATE(YEAR(TODAY()),A2,8-7))
(from Bob Philips)

4.) the closing date of the end of the month in week 5 worksheet


=DATE(YEAR(TODAY()),$A$2+1,0)

Regards,
Stefi