cancel
Showing results for 
Search instead for 
Did you mean: 

Object type PROG (SE38) not supported in SAP ABAP Cloud.

Vincent801
Explorer
0 Kudos

Dear ABAP Cloud Experts,

Currently I am working in migrating the Old BW flows to BW Bridge.We have many SE38 programs and Include programs in BW System. But while moving the programs from BW system -> GITHUB -> BW Bridge Cloud system. The Programs are not able to move and I am getting the message as

Object type PROG not supported in SAP Cloud Platform, ABAP Environment. The import of this object is skipped.

Could you please guide me, what is the replacement of SE38 programs and include programs in ABAP Cloud.

Thanks.

Sandra_Rossi
Active Contributor
0 Kudos
Classes.
Sandra_Rossi
Active Contributor
0 Kudos
Classes.
View Entire Topic
Edrilan_Berisha
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Vincent801,

 

ABAP programs were used during a time where object oriented development was not so popular. In ABAP OO they should be not used. 

For the ABAP Cloud you have all objects which are supported here: https://help.sap.com/doc/abapdocu_cp_index_htm/CLOUD/en-US/index.htm?file=abenreleased_apis.htm

 

I would propose to convert the program, you simply create a class and there in this class you implement the interface IF_OO_ADT_CLASSRUN

As example:

 

 

CLASS zprogram_demo DEFINITION
  PUBLIC
  FINAL
  CREATE PUBLIC .

  PUBLIC SECTION.
    INTERFACES if_oo_adt_classrun.
  PROTECTED SECTION.
  PRIVATE SECTION.
ENDCLASS.


CLASS zprogram_demo IMPLEMENTATION.
  METHOD if_oo_adt_classrun~main.
    out->write('Hello ABAP Cloud World!').
  ENDMETHOD.
ENDCLASS.

 

 

Best,

Edrilan Berisha

SAP S/4HANA Cloud Financials Development

 

 

Vincent801
Explorer
0 Kudos

Thank you very much Edrilian for the quick reply and the sample program. I ran your program with the Option Run As -> 1. ABAP Application (console) and i am getting the result correctly.

For function Modules, I dont have option to Run As -> 1. ABAP Application (Console). Sample function module Code attached below. Could you please guide me how to execute Function Modules in Eclipse ?

function zfm_operator
  importing
    num1 type string
    num2 type string
    operator type c
  exporting
    sum type string.
if operator = '+'.
sum = num1 + num2.
elseif operator = '-'.
sum = num1 - num2.
elseif operator = '/'.
sum = num1 / num2.
endif.
ENDFUNCTION.
Edrilan_Berisha
Product and Topic Expert
Product and Topic Expert

Hi Vincent801,

 

what are you trying to achieve? You want to implement a function module in ABAP Cloud? If yes I would refrain from that, function modules just like programs are from pre-ABAP OO time. We do not use them in current development as they are outdated. I would rewrite and implement the coding in a new method so instead of function zfm_operator, you create a method in your class called METHOD operator. If you want to call a remote function module you find a blog post here: https://community.sap.com/t5/technology-blogs-by-members/call-a-remote-function-module-rfc-from-sap-...

 

Best, Edrilan Berisha