View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
dylan dylan is offline
external usenet poster
 
Posts: 26
Default Please help with simple function

I'm trying to create a function which will replace a formulae containing
nested If statements. I'm looking for some help, because I don't have much
experience with Functions.

Here is the cell formulae
IF(COUNTIF(B2,"<Z*"),0,IF(F20,(F2+$F$270+(IF(G20 ,G2+$G$270,0))-(H2+$H$270)),IF(G20,(G2+$G$270+(IF(F20,F2+$F$270 ,0))-(H2+$H$270)),"")))

It applies the following logic to each row, presenting a result in Cell I of
each row.
With each column in F-H, If the Cell 2 value is greater than 0, add Cell 2
to Cell 270. Then apply (F+G)-H to calculate the result.

I'm stuck at the beginning with cells containing text.
'If the cell value is text then the result = 0
If myC.Value < "Z" Then SumInvoice = 0 'doesn't work?

Dylan