NAV2009SP1 classic.
I've created a codeunit which opens an Excel file, do some things and closes the excel file.
This is running correcty, but not when I run this codeunit from a NAS.
Just to isolate the problem i've create a new codeunit with the following code in the OnRun trigger
T370.OpenBook('\\sharename\tmp\Test.xlsx','Sheet1');
If I run this codeunit from the objectdesigner everything works fine. No forms, exceldiaglogs or windows are opened.
I've attached this codeunit to the jobqueue and started the NAS.
In the Job Queue log entry I get the following error:
[The call to member Open failed. Microsoft Excel returned the following message:
Microsoft Excel cannot access the file '\\CNU0333Q5F\tmp\Test.xlsx'. There are several possible reasons:
• The file name or path does no•
Even more strangly is that, when I start the NAS from the commandprompt the Jobqueue is executed correctly.
I'm sure that this has nothing to with userright etc. because everyting is executed with administrator rights.
The suggestions in
viewtopic.php?f=23&t=38483&start=0 and
viewtopic.php?f=23&t=26971&hilit=excel+NAS&start=15 does not solve the problem
Does someone has a clue how to solve this?
Answers
viewtopic.php?f=23&t=41423&hilit=Excel+desktop
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
What I did to overcome this problem is to create pairs of codeunits. The first of the pair creates the file. The second emails it. The 2nd of the pair can find the file.
Thanx for your help!
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
add folder:
C:\Windows\SysWOW64\config\systemprofile\Desktop (if 64 bit)
C:\Windows\System32\config\systemprofile\Desktop (if 32 bit)
and work on the excel file from here