Ifs

M

myname

Dear group,
I'm trying to calculate the attendance allowance as follows:
1) if accumulated 2 or more days of sick leave from beginning of year to
last month,

a) and current month has 0 days sick leave, attendance allowance (AA)
for current month = 50
2) if current month has 1 day sick leave, AA = 25
3) if current month has 2 or more days of sick leave AA= 0

2) if accumulated sick leave from beginning of year to current month
does not exceed 2 days, then current month AA = $50.


staff name acc to last mth current mth AA
a 2 days 1 day $25
b 2 days 2 days $0
c 1 day 1 days $50
d 1 day 2 days $25
e 0 days 1 day $50
f 0 days 2 days $50
g 0 days 3 days $25
h 0 days 4 days $0
i 2 days 0 days $50
j 1 day 0 days $50

thanks
jl
 
S

Sam Wilson

If cell A1 was the title "Staff name", B1 was "Acc to last month" etc... put
this in cell D1

=if(B1>1,if(C1=0,50,if(C1=1,25,0)),50)
 
M

myname

Thanks, that worked.

Sam said:
If cell A1 was the title "Staff name", B1 was "Acc to last month" etc... put
this in cell D1

=if(B1>1,if(C1=0,50,if(C1=1,25,0)),50)
 

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