I have a batch report to export a text file.
I was able to run it through RTC client because I use CDO 419.
New request need to stop prompt common dialog windows and read from a setup table the destination location of the exported file.
The code before was:
DOWNLOAD(FileName, '', SetupTbl.Path, '', FileName2);
and I thought I have to change the Setuptbl.Path only by entering the Magic Path so the new code is
DOWNLOAD(FileName, '', '<TEMP>', '', FileName2);
The problem is the file is not saved to the specific path. I don't have any error message at all. I remove the Magic Path the prompt ask me where to save and it work. I put on the magic path and the file does not work.
Filename is the full path of the file created on the RTC server.
Filename2 is the full path of the destination file I want to create.
Can anyone help?
Comments
notice here in the NAV code from COD 419 it assigns the MagicPath first to a variable and then uses the variable as the parameter
hope this helps
Steve
http://mibuso.com/blogs/mohana/2011/02/20/file-export-in-rtc-with-%e2%80%9ccommon-dialog-management%e2%80%9d/
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
I use the internal function DOWNLOAD and I don't have any problem with prompt, the problem is the non prompt way. From the moment I used the magic path the file stop copy itself from server to client. If I use the prompt it worked. If you know there is a bug in DOWNLOAD function of Navision ok I will use wsHost but I will report this to Microsoft.
Thanks Mohana for the idea.
welcome
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav