Showing results for 
Search instead for 
Did you mean: 

It's possible to change an Activity (OCLG) object from one Service Call (OSCL) object to another?

0 Kudos


I am developing an api restful in C# which receives a JSON object and inserts it into SAP, my problem is transfer this Activity (OCLG) object from one Service Call (OSCL) object to another if the operator was wrong.

Example Code:

// Connection to SAP... oCompany object....

CompanyService oCompanyService = oCompany.GetCompanyService();

ServiceCalls oServiceCalls = (ServiceCalls)oCompany.GetBusinessObject(BoObjectTypes.oServiceCalls);

ActivitiesService oActivitiesService = (ActivitiesService)oCompanyService.GetBusinessService(ServiceTypes.ActivitiesService);

Activity oActivity = oActivitiesService.GetDataInterface(ActivitiesServiceDataInterfaces.asActivity);

// variable assignment ...

ActivityParams oActivityParams = oActivitiesService.AddActivity(oActivity);

int oActivityCode = oActivityParams.ActivityCode;


oServiceCalls.Activities.SetCurrentLine(oServiceCalls.Activities.Count - 1);

oServiceCalls.Activities.ActivityCode = oActivityCode;


How can I change the activity of the call service? // SCL5 relationship.


through a query would be:

UPDATE SCL5 SET SrvcCallId = new_service_call_id WHERE SrvcCallId = old_service_call_id AND ClgID = object_id

Accepted Solutions (0)

Answers (0)