View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Santiago[_2_] Santiago[_2_] is offline
external usenet poster
 
Posts: 26
Default This code won't work, any ideas?

I'm pretty new with programming in excel. I'd like to know why the following
code does not insert the formula in the cell "P" & fila. Fila is a variable
(number) that changes in a loop.


Range("P" & fila).Formula = "=IF(H" & fila & "="",IF(G" & fila & "="","",G"
& fila & "-E" & fila & "),H" & fila & "-E" & fila & ")"

Thanks!

Bregards

Santiago