formula or code help

J

Joe@excel

Help please…
We have meetings every month. On Sunday’s and Wednesday
And every month we generate a task list for Sunday’s and Wednesday’s or
vise versa it all depends in the month. For example on November I would
have started on a Wednesday. For December I will start on a Sunday.
But it’s only for a month at a time.

A6=Data!F8
A7=IF(TEXT(A6,"dddd")="Sunday",A6+3,IF(TEXT(A6,"dddd")="Wednesday",A6+4))
A8=IF(TEXT(A7,"dddd")="Sunday",A7+3,IF(TEXT(A7,"dddd")="Wednesday",A7+4))
A9=IF(TEXT(A8,"dddd")="Sunday",A8+3,IF(TEXT(A8,"dddd")="Wednesday",A8+4))
A10=IF(TEXT(A9,"dddd")="Sunday",A9+3,IF(TEXT(A9,"dddd")="Wednesday",A9+4))
A11=IF(TEXT(A10,"dddd")="Sunday",A10+3,IF(TEXT(A10,"dddd")="Wednesday",A10+4))
A12=IF(TEXT(A11,"dddd")="Sunday",A11+3,IF(TEXT(A11,"dddd")="Wednesday",A11+4))
A13=IF(TEXT(A12,"dddd")="Sunday",A12+3,IF(TEXT(A12,"dddd")="Wednesday",A12+4))
A14=IF(TEXT(A13,"dddd")="Sunday",A13+3,IF(TEXT(A13,"dddd")="Wednesday",A13+4))
A15=IF(TEXT(A14,"dddd")="Sunday",A14+3,IF(TEXT(A14,"dddd")="Wednesday",A14+4))
A16=IF(TEXT(A15,"dddd")="Sunday",A15+3,IF(TEXT(A15,"dddd")="Wednesday",A15+4))

Data!F8 in this cell I enter the first day that we’ll meet.

For December 2005 right now, the result I get is as follows.

A6 Sunday 4 December 2005
A7 Wednesday 7 December 2005
A8 Sunday 11 December 2005
A9 Wednesday 14 December 2005
A10 Sunday 18 December 2005
A11 Wednesday 21 December 2005
A12 Sunday 25 December 2005
A13 Wednesday 28 December 2005
A14 Sunday 1 January 2006 ===) to avoid January to apper I tried the
following.
A15 Wednesday 4 January 2006===) to avoid these
A16 Sunday 8 January 2006===) to avoid these

A3 =COUNTIF(Sheet2!B6:B16,MONTH(F8))and it does gives me count of 8

B6=month(a6)
B7=month(a7)
B8=month(a8)
B9=month(a9)
B10=month(a10)
B11=month(a11)
B12=month(a12)
B13=month(a13)
B14=month(a14)
B15=month(a15)
B16=month(a16)

Then I go back to

A7=IF(TEXT(A6,"dddd")="Sunday",A6+3,IF(TEXT(A6,"dddd")="Wednesday",A6+4))

To A16 and enter the following to each.

A6=If(A3>=1,IF(TEXT(A6,"dddd")="Sunday",A6+3,IF(TEXT(A6,"dddd")="Wednesday",A6+4)),””)
A7=If(A3>=2
A8=If(A3>=3 Etc. until A16

But it’ll read that it can not do a circular formula. And wont do
anything..

Is there another way to do it?

Thank you…
 
?

????...

select the area where you wanna.
format -> cell -> number -> custom -> type:
set: dddd d mmmm yyyy

A B
1 4/12/05 =A1+3
2 =A1+7 =B1+7

Select A2:B2, draw downwards!

I'm a Chinese, I can't say any more in English!

I would like to make friends with you, and you????
 
B

Bob Phillips

From A7 down you could use

=IF(A7="","",IF(MONTH(IF(WEEKDAY(A7)=1,A7+3,IF(WEEKDAY(A7)=4,A7+4)))=MONTH($
A$6),IF(WEEKDAY(A7)=1,A7+3,IF(WEEKDAY(A7)=4,A7+4)),""))

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
R

Roger Govier

Hi Joe

Could you not just use in A7
=A6+3*(WEEKDAY(A6)=1)+4*(WEEKDAY(A6)=4)
and copy down through cells A8:A16

If you don't want dates in the following month to show, then use Conditional
Formatting on cells A14:A16
Format>Conditional Formatting>dropdown to select Formula
is>=MONTH(A14)<>MONTH($A$6) and set text Format to White.


Regards

Roger Govier
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top