Hi,
I am facing a strange issue with NAS and Job Queue.
I needed to create a file each morning so I created a Codeunit that makes the hard work. In a given moment, the codeunit is calling a report that will actually create the file xxx.txt in a folder C:\TEMP\
Everything goes well and running smooth when I run the codeunit manually: Alt+R from the Object Designer.
But when I put that same codeunit in the Job Queue, I get this error:
The operating system cannot find the drive and directory specified for the file C:\TEMP\xxx.txt .
Please check that the drive, directory and file names are correct.
I am very puzzled. What I am doing wrong?? ](*,)
Answers
BTW: You would better use : ENVIRON('temp') to know which is the temp directory on any computer.
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
Epimatic Corp.
http://www.epimatic.com
I get around that by putting a dummy file in the subdirectory. For example:
X:\Temp\dummy.txt [X:\ is a Network Drive]
Then before I write to the Temp folder, I would first check if the file dummy.txt in that directory exist, if it is then it is a good Path, then I write my output file to that directory.
Files."Is a file"
or
FILE.EXISTS(FileName)
I don't know if you have the same scenario, but I hope this will help.
NIEM THAI
Epimatic Corp.
http://www.epimatic.com
Thank you VERY MUCH for your answers, they were really useful and helped me to solve the issue as they forced me to review everything from scratch.
I was pointing to a wrong computer in the network! :oops: In that computer the folder C:\TEMP didn't existed... :oops:
As far as I created the folder in the right computer, everything went well. \:D/
Thank you again for your help, guys!!
"I don't want to believe. I want to know." (Carl Sagan)
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
"I don't want to believe. I want to know." (Carl Sagan)