Skip to Content

SCP IoT Service Reading Registered Devices with OPENUI5

Jun 08, 2017 at 08:30 AM


avatar image
Former Member

Hi everyone,

i try to read all registered devices from SCP IoT Service and store the response in a JSON Model. I want to load the data in my Component.js. This is the code i use to load the data:

//create "json" model
var oModel = new sap.ui.model.json.JSONModel();
//load data from URL
"", true, "GET", false, "false", {
Authorization: "Basic mybase64encrypted USER:PW"

When starting my application i get this error:

XMLHttpRequest cannot load https://<host>/". Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'myapplicationURL' is therefore not allowed access.

Has anyone a suggestion where I need to adopt the code?

Thanks for every help.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

0 Answers