08-31-2008 9:04 AM
Hi all.
Does anyone know a way to activate a batch file threw abap?
Thanks in advance,
Rebeka
08-31-2008 9:06 AM
Hi Rebeka,
Have a look at function module GUI_EXECUTE or WS_EXECUTE. Another way to do this if the batch file is on the server is to use transactions SM69 and SM49 and then function module SXPG_COMMAND_EXECUTE.
Regards,
C.A
08-31-2008 9:06 AM
Hi Rebeka,
Have a look at function module GUI_EXECUTE or WS_EXECUTE. Another way to do this if the batch file is on the server is to use transactions SM69 and SM49 and then function module SXPG_COMMAND_EXECUTE.
Regards,
C.A
08-31-2008 9:15 AM
Hi.
First of all, thanks..
Second, that's exactly the problem:
I'm activating FM SXPG_COMMAND_EXECUTE with a command that cannot work on background.
For that reason we had created a batch file ...
FM gui_execute does not exist and WS_EXECUTE cannot work with batch mode......
My only possible way is to find a fm that can activate a batch file and works with background mode.
I'll apriciate it if you could help me find one.
Regards,
Rebeka
08-31-2008 9:18 AM
Hi Rebeka,
Try using fm rfc_remote_exec.This works in background.
Regards,
C.A
08-31-2008 9:21 AM
08-31-2008 9:24 AM
HI Rebeka,
You won't find it because the fm resides on the gui. So just refer to oss note 77075 on service.sap.com on how to use it.
Regards,
C.A
08-31-2008 9:27 AM
Preconditions / Restrictions, for example:
- Available from R/3 Release 2.1.
- You can execute extensions .com/.exe/.bat.
- Install the RFC server program RFCEXEC.EXE with the Desktop Development Kit.
- The destination (in the example, LOCAL_EXEC) was created with transaction SM59
Example 1: call the program TEST1.EXE. report ztest1.
data: Path1(256) type c value 'C:\PROGRAM FILES\TEST1.EXE' .
call function 'RFC_REMOTE_EXEC'
destination
'LOCAL_EXEC'
exporting
COMMAND = Path1 .
Most probably you would have the rfcsdk installed on your desktop
Regards,
C.A