Hi Stevanus
I think, I found the problem point:
The base class SysExcel's property 'RunOn' is set to 'Client' (AX 2009).
That means, that this class can only used client side.
I see two options:
1. Change this property to 'called from' and compile forward, but on the
other hand this can raise some other problems
2. Build your own (or extended) SysExcel classes which can used for Server
and for Client and use these.
Sorry for that bad news, but it looks like work to get your Excel creation
running with batch.
About runImpersonated; I don't know about this method, but may be it
defines, if the batch must run in context of the user which has sheduled the
batch or if the batch can run with administrator rights??
Regards
Patrick
Post by Stevanus HKI forgot the exact code for the line 4 because i have been modified my code,
but it is beetwen 3 line code i write here
_sysexcelapplication = SysExcelApplication::construct();
_sysexcelworkbooks=_sysexcelapplication.workbooks();
_sysexcelworkbooks.add();
Post by LuegisdorfSorry, I was irritated by 'runJobStatic', but what is the command line of
ExcelBatch.run line 4?
There seems to be the problem point.
Regards
Patrick
Post by Stevanus HKHi Patrick
i didn't run a job, i run a class that extend runbasebatch class
Regards
Stevanus HK
Post by LuegisdorfHi Stevanus
Jobs can be runned only on client tier. Move your x++ code from job to class
and it should run.
Regards
Patrick
Post by Stevanus HKThe server-side impersonated (RunAs) session tried to invoke a method that is
available for client-side processing only. (S)Classes\ExcelBatch\run-line 4
(S)Classes\BatchRun\runJobStatic-line62
Post by LuegisdorfHi Stevanus
Can you post the exact error message?
Regards
Patrick
Post by Stevanus HKI did change the run on property to server and off course ms excell installed
on the server and the file placed on the server. but still doesn't work for
me.
Post by LuegisdorfHi Stevanus
Batch in AX 2009 runs on server, there's no client connection, therefore
client-side classes cannot be run.
I suggest to change the runOn property on that class to get it run. But you
have to place the file on server's file system .. and MS Excel needs to be
installed on server too ...
Regards
Patrick
Post by Stevanus HKi use ax 2009, error message said that client side code can't run on server
side something, forgot the exact message.
Post by Markuswhat version of AX do you use,
whats the error message ?
--
http://www.linkedin.com/in/noebauer
https://www.xing.com/profile/Markus_Noebauer
Post by Stevanus HKhello,
I made an application to export and import excel Data with sysExcel, i want
to run this application on batch server, but sysexcel just run on client
side, i want to know how to create application to export and import excel
data that can run on batch server