View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
gbiwan gbiwan is offline
external usenet poster
 
Posts: 23
Default even/odd returns 1 0r 16

FANTASTIC!

THANKS Frank!

I really do appreciate your help!

Greg

"Frank Kabel" wrote in message
...
Hi
just enter in the cell for column E the following formula:
=IF(COUNTIF($X$1:$X$100,E$6)=1,"STAT","")
copy this to the right

--
Regards
Frank Kabel
Frankfurt, Germany

Gbiwan wrote:
Thanks Frank!

This did the trick!

Is there a way to format a cell in the row below based on the result
of the conditional formatting? (or countif formula?) I'd like to
return STAT in the cell directly below the conditionally formatted
holiday result... any ideas?

Thanks again for your great HELP!

TTFN
Greg

"Frank Kabel" wrote in message
...
Hi
see below

In cell "E6" I would like to return either 1 or 16 based on the
result of a lookup table in cell "DB4". The easiest would be if

the
answer was even then "16" would be returned. If it was odd then
"1". I know that there is an easy solution but can't get me head
around it...

try
=IF(MOD(your_lookup_formula,2)=0,16,1)


What I'm trying to do is to change the dates on a payroll sheet...
this seems like the easiest way to do so... however if somebody
could tell me a way to populate the columns to the right of the
first day of the pay period ("E6") based on a period picked from a
control that would be even better!

not quite sure what you're trying to achieve but if you insert a

date
in E6 you can use the following in F6
=E6+1 - included weekends
or
=WORKDAY(E6,1) - if you want only workdays
copy both to the right


Then I think that there's a way to mark and identify Holidays
correct? In the perfect world... the user would pick a pay
period... the cells "E6" to "T6" would fill in the dates and if
there was a holiday during that period that the column would be
highlighted... could that be done?

one way:
- you have stored your holiday dates in a separate range (lets say
X1:X100)
- highlight the columns E6:T6
- goto 'format - conditional format' and enter the following formula
=COUNTIF($X$1:$X$100,E$6)=1
- choose your format for the holiday columns


Frank