Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Very Urgent:How to move file on application server directory?

Former Member
0 Kudos
84

In my report I have to move file in application server folder other folder.

for ex:currently file is in '/xfer/IN/'

I have to move file to '/xfer/OUT/' after reading from '/xfer/IN/'.

please tell me code.

3 REPLIES 3

Former Member
0 Kudos
63

HI,

is it on unix... if yest do this..

DG_UNIX_LOC = 'mv /xf/in /xf/out'.

DATA : V_STRING(100) TYPE C.

REFRESH DT_TABL.

CALL 'SYSTEM' ID 'COMMAND' FIELD DG_UNIX_LOC

ID 'TAB' FIELD DT_TABL-SYS.

0 Kudos
63

it is not on unix.

maciej_domagaa
Contributor
0 Kudos
63

1. Use SM69 to define an OS command. On Windows it can be: "cmd /c MOVE /Y".

2. Then use CALL FUNCTION 'SXPG_COMMAND_EXECUTE' to run it from ABAP code.