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

ws_upload or upload ?

Former Member
0 Likes
608

Hi all,

I see people are working on the long weekend too.. Oh.. life as an ABAPer...

What is the difference between ws_upload and upload functions? Which to use? I think the same difference would apply to ws_download and download too.. right?

Could you give examples too?

What is presentation server counterpart for ws_query (which is used for finding the file size of application server files)?

Thanks.

Charles.

++++++++++++++++++++++++++++

1 ACCEPTED SOLUTION
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
572

There is a class since 4.6 called CL_GUI_FRONTEND_SERVICES, it includes all kinds of methods to help you interact with the frontend(presentation server) include a GUI_DOWNLOAD and GUI_UPLOAD methods. You should use these instead of the older function modules. Yes, these methods call the function module in there implementation, but this will get you used to using class/methods. This will help you in understanding ABAP OO.

Regards,

RIch Heilman

Hi all,

I see people are working on the long weekend too.. Oh.. life as an ABAPer...

What is the difference between ws_upload and upload functions? Which to use? I think the same difference would apply to ws_download and download too.. right?

Could you give examples too?

What is presentation server counterpart for ws_query (which is used for finding the file size of application server files)?

Thanks.

Charles.

++++++++++++++++++++++++++++

3 REPLIES 3
Read only

Former Member
0 Likes
572

hi,

Both upload and ws_upload does the same functionality, that is transfere data from presentation server to application server or from PC to SAP system(to an internal table).

There are very few difference between the two.

1 Upload requires a User Interaction for uploading i.e., user has to respond to the dialog boxes that appear WS_Upload does not. You just need to specify the file location in the function input parameters itself.

2 upload - u can give the file in run time wsupload - u have to give in Function module

3 upload is meant to be used by abappers. ws_upload is meant to be called by SAP. It is not a standard ABAP command.

4 ws_upload is Obsolete : No longer supported by SAP. Use GUI_UPLOAD instead.

Regards,

Naveen

Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
573

There is a class since 4.6 called CL_GUI_FRONTEND_SERVICES, it includes all kinds of methods to help you interact with the frontend(presentation server) include a GUI_DOWNLOAD and GUI_UPLOAD methods. You should use these instead of the older function modules. Yes, these methods call the function module in there implementation, but this will get you used to using class/methods. This will help you in understanding ABAP OO.

Regards,

RIch Heilman

Read only

uwe_schieferstein
Active Contributor
0 Likes
572

Hello Charles

You should only use the class CL_GUI_FRONTEND_SERVICES for Upload/Download because the function modules are not unicode compatible.

If you use the function modules you will have to replace them as soon as your programs need to unicode-enabled.

Regards

Uwe