Well Ralph I made a mistake makeing it to work as DateValue(DateValueUS).
Since DaveValueUS is already date value, again DateValue() is causing the
error.
SO try below:
ActiveCell.FormulaR1C1 = _
"=IF(RC[-2]=(DATEVALUE(""1986/1/1"")),(" & DATEVALUEUS &
"-RC[3]),(" & DATEVALUEUS & "-RC[-2]))"
Sharad
"Ralph Elmerick" wrote in message
...
Sharad Thanks.
I tried your suggestion and now I get
=IF(D2=(DATEVALUE("1986/1/1")),(DATEVALUE(38353)-I2),(DATEVALUE(38353)-D
2))
in the field with #VALUE in the field. The DateValueUS is indeed 38353
so we have made progress it just does not provide the value I need for
the number of days. It is not making the subtraction between the dates.
Thanks
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!