2007 Mar 28 8:24 AM
How To execute a Remote EXE from SAP ?
Hi,
We are having a case where in from SAP(ABAP) we have to execute a remote
EXE. This Remote EXE can be accessable by sharing the Drives or mapping the drive. i tried using WS_EXECUTE or GUI_EXEC it is not working it gives me the following error.
Component MSWINSK.OCX or one of its dependicies not correctly registered: a file is missing or invalid.
Is it that WS_EXECUTE or GUI_EXEC expect the exe to be available locally. ?
or do i have to create the RFC destination ?
we are on win2K.
Regards,
Umesh
2007 Mar 28 8:54 AM
You can use SXPG_COMMAND_EXECUTE after defining command for particular OS in SAP.
2007 Mar 28 9:23 AM
Sanjay,
to explain you more on this. Actually the O/s we are having in HP/UNIX but the desktop are all win2k. So from GUI we want to execute some EXE with parameter. can you tell me in detailed how to do this step by step or some sample code if you can give.
Regards,
Umesh
2007 Mar 28 9:32 AM
maintain your command in SM69. You can search this forum with FM name to find example...
2007 Mar 29 8:27 AM
sanjay,
I think still you have not understood my point. Though our SAP is on HP/Unix but the frontend we are having is all Windows. The FM which you have specified is look like more to Unix or application server oriented. For me i have to execute an EXE on presentation server with some parameters.
Again kindly note that this EXE can be accessable by sharing a remote drive. it is not residing on my presnetation server. (e.g. G: or I: etc.)
when i am using ws_execute it is giving me the invalid path error.
kindly help.
2007 Mar 29 9:41 AM
2007 Mar 29 10:07 AM
FM which i suggested it mostly for application server but since you want it on presentation server you can try what previous poster have suggested....
It seems it may be due to your shared drive or permission etc..
2007 Mar 29 10:43 AM
NO i have not try this.... Method.
Do u have any code which can show how to execute an EXE with some parameters.
kindly help me....
2007 Mar 30 5:56 AM
Hi Sanjay,
Thanx for your reply.... Actually i tried using GUI_EXEC or other GUI related FM. but as i told u earlier it is having some path problem. & more over it is bit risky also. so now we have decided to go for Machine to machine via WAN.
first of all is this option right.? if yes the following is the update.
first of all our sap is on HP\UNIX the EXE which i want to execute is on windows machine which is Remote machine. This Exe expect some parameters.
It also expect some file to be created in that remote machine which is an input to this exe.
can you pl. tell me step by step how i can do this. & even a progam or FM which can create a file on the remote machine. i dont want to do the shared drive business. because it could be risky.
how abt. RFC port ?