Application Development and Automation 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: 
Read only

Editing text file on application server

Former Member
0 Likes
1,867

Hello,

I have created a utility in which I can move files from one folder to another. Now we also need a option by which I can edit text file on the server folders. Is there a function module by which I can edit text from application server ?

Regards,

Rajesh.

1 ACCEPTED SOLUTION
Read only

Sm1tje
Active Contributor
0 Likes
1,066

Don't think there is, but if you are able to move files from one to another, you should also be able to show these files, edit them and download them again to server.

4 REPLIES 4
Read only

Sm1tje
Active Contributor
0 Likes
1,067

Don't think there is, but if you are able to move files from one to another, you should also be able to show these files, edit them and download them again to server.

Read only

Former Member
0 Likes
1,066

Hello,

I am able to move files, but how can I show them and edit them ?

Regards,

Rajesh.

Read only

Sm1tje
Active Contributor
0 Likes
1,066

With OPEN DATASET and READ you can load them into an internal table. Next put them on screen in lets say the text editor (enjoy SAP Controls). This is one way of doing this, other way would be:

Upload data with OPEN DATASET into internal table, download file to local drive (cl_gui_frontendservices=>gui_download), open it with notepad (for example) edit it and save. Next upload file into your program (cl_gui_frontendservices=>gui_upload) and download it to server again (OPEN DATASET and TRANSFER).

If available you can also use transaction CG3Z and CG3Y.

Read only

Former Member
0 Likes
1,066

Are you moving the files using OS level commands or copying them creating at new directory and deleting old one?

If you are not reading the files theni am not sure what can be done.

If you are reading them in your program then you should be able to edit the text in between.