I am trying to write a single data file through Report/Device features. However, it always makes a new entry at the end of the file. How to avoid this? I would like to overwrite this file.
I tried to write data from Cicode via DDEWrite() function, but it didn't work for me. How to correctly define variables in Wordpad?
FileCopy("C:\DataSCADA\Reports\ALReportDraft.rtf", "C:\DataSCADA\Reports\Report.rtf", 0);
Exec("C:\Program Files\Windows NT\Accessories\wordpad.exe C:\DataSCADA\Reports\Report.rtf", 6);
Sleep(3);
DDEWrite("wordpad", "C:\DataSCADA\Reports\Report.rtf", "LoadArmID", AL11LoadArmID);
DDEExec("wordpad.exe", "[Close(1)]");
DDEExec("wordpad.exe", "[Quit]");