I try to write a formulas into the cell. I can save the file but if I open this from Excel, Excel tell me the file contains a bad character.
The problem come of this function : NETWORKDAYS.
Code: Select all
...
DestXLSDoc.Sheet[0].AsFormula[40,DestRow] := 'IF(OR(A'+DestRealRow+'=""; ISTEXT(A'+DestRealRow+'));"";IF(NOT(AN'+DestRealRow+'="X");"NON";IF(ISERR(DAY(AM'+DestRealRow+'));"";IF(NETWORKDAYS(AM'+DestRealRow+';A'+DestRealRow+')>2;"OUI";"NON"))))';
...
Have you any solution of this problem please ?
Thank you for your help.