cancel
Showing results for 
Search instead for 
Did you mean: 

SICF CALL

05-19-2015 4:30 PM
jordi_candel Explorer
955 views 4 comments Go to solution
0 Likes
SAP Managed Tags
Subscribe

Hello guys,

i have a little service I created via Transaction SICF. This service does nothing else than return a json string via HTTP.

How can I call this service from a SAPUI5 application? (The SAPUI5 application is not deployed  on the ABAP Server, instead it is running locally on my client)

var oModel = new.sap.ui.model.json.JSONModel();

oModel.loadData("http://xxx.server.com:8000/myServicePath"); is not working. Any idea?

Thanks

Goluef

0 Likes

Accepted Solutions (1)

Accepted Solutions (1)

0 Likes

In Transaction SICF, right click on your service node -> test Service.

Here you can test your service directly in your browser.

Are you setting username and password for your request?



var mParameters = {

        username: "user",

        password: "password"

}

var oModel = new.sap.ui.model.json.JSONModel();

oModel.loadData("http://xxx.server.com:8000/myServicePath",mParameters);


If the application runs locally and the service is hosted on your ABAP-System, it could also appear in a problem.

Something like "Allow control Allow Origin" should appear in your browsers console. Google for that problem, i'm using a chrome plugin to access Gateway services, when the application is running locally.

jordi_candel
Explorer
0 Likes

Thanks a lot.

Answers (1)

Answers (1)

Former Member
0 Likes

Do you mean the service is running on a localhost server, e.g. Tomcat or Apache?

jordi_candel
Explorer
0 Likes

the service is running on the ABAP System, the SAPUI5 app is running locally on my laptop.