2012 Sep 17 9:03 AM
Hello all,
I created a function module and i use cl_gui_frontend_services=>execute method in this FM to trigger a BAT file in local computer.
When i run this function module in debug mode, i simply run this method with F6 and it works, but when i call this FM directly without debugging, this method doesnt work.
I read that this class doesnt work in background process. So how does it work in debug mode? Is there a way to run this method in function module?
Thanks..
2012 Sep 17 9:07 AM
Hello,
if you are working in debugging-mode, your report has an active connection to your local workstation through SAP GUI. With this connection, it is possible to create lcoal files via the class CL_GUI_FRONTEND_SERVICES.
If your report is running in batch-mode, you cannot access to your local workstation, because there is no one. All things are running on an workprocess-instance on your application server having no GUI-connection.
At least, you cannot know, which user has started your report in background and create a file on his workstation.
Kind regards,
Hendrik
2012 Sep 17 9:12 AM
Hi Aydin,
CL_GUI_FRONTEND_SERVICES class does not work for BG or other GUI functions....find alternate solution.
And as per knowledge debug mode is forground mode process.
Thanks,
Amol
2012 Sep 17 9:28 AM
What do you suggest for that? How can i trigger a BAT file at my local computer?
2012 Sep 17 9:33 AM
The question of how to get a file to a local workstation in background has been discussed many times. Please search. Thread locked.