Thread: just weekdays
View Single Post
  #10   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips Bob Phillips is offline
external usenet poster
 
Posts: 380
Default just weekdays

Sure, it is quite straightforward.

The easy bit

=C2+1 - advance the date one day

test if the date is a Friday

WEEKDAY(C2)=6

which returns a TRUE or FALSE, which when multiplied by 2 gives 2 or 0, so
on a Friday another 2 days gets added, any other day, 0 days get added.

--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)

"peter the swede" wrote in message
oups.com...
dear Bob
can you explain that a little bit more ps?

No need to check for Sunday, the Saturday check will skip it

=C2+1+(WEEKDAY(C2)=6)*2

--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)

"peter the swede" wrote in message
oups.com...
Hi all
on a spreedsheet I´ve a series with dates, where from previous date 1
day is added (i.e. C3=C2+1).
Now I wan´t to do the following:
1) check if C10 is a saturday?
2) if C10 is saturday than go to monday
3) check if C10 is sunday ?
4) if yes then add 1 day
5) if C10 is not sunday, than add 1 day

I hope you understand what I want to do

Thanks in advance
//Peter