Create a file on the server with TEMPORARYPATH

poppinspoppins Member Posts: 647
edited 2015-04-22 in NAV Three Tier
Hi everyone,

I am running a report from my machine on the server side.The report is supposed to create a log file to collect errors.
Here is the code I wrote:
lFileName := STRSUBSTNO(TextXXX,DELCHR(FORMAT(WORKDATE),'=','/'));
ltextPath := TEMPORARYPATH + lFileName;
LogFile.CREATE(ltextPath);
FileMgt.DownloadToFile(ltextPath,SalesSetup."Logfile Path"+lFileName);

I get the following error:
An I/O exception occurred during the operation.
With the debugger, the error is from the call to function DownloadToFile().
Is my code for the file creation correct?
Sign In or Register to comment.