Thread: help in syntax
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Ajtb Ajtb is offline
external usenet poster
 
Posts: 41
Default help in syntax

Hi
I think this will work.

..FormatConditions.Add Type:=xlExpression, Formula1:= _
"=IF(COUNTIF(rRange , sCell)1,TRUE,FALSE)"


Regards
Andrew Bourke



james wrote:
I am trying to write the following formula into cell.

.FormatConditions.Add Type:=xlExpression, Formula1:= _
"=IF(COUNTIF("&rRange & "," & sCell&")1,TRUE,FALSE)"

where rRange and sCell are range variables.
I got syntax error.
Would anyone help?

Thanks in advance.