Skip to main content
1-Visitor
March 31, 2016
Solved

How to load an xml file from the system in the script. I tried:

  • March 31, 2016
  • 5 replies
  • 2676 views

var params = {

url:"file://C:/Users/ShaurabhKumar/Documents/MATLAB/AGENT.xml",

timeout:160

};

Got Error:

Wrapped org.apache.http.client.ClientProtocolException Cause: null

I am trying to read an xml file on my system.

Is there any other way to do the same?

Thank you

Best answer by PaiChung

Uploaded file would only be a snapshot.

if you have something that is updating the XML file continuously, if you can, you could post the incremental updates to Thingworx using either the Edge MicroServer or the REST API

5 replies

22-Sapphire I
April 1, 2016

Not sure if that is possible, could be a variety of reasons, I recommend you create a mashup and do an upload of the file to a repository and process it from there.

ssingh-311-VisitorAuthor
1-Visitor
April 1, 2016

Yes I believe that would be one way of doing it. But what if the xml file keeps updating with time(real time data). If i store it in the repository would it simply store a version of it?

PaiChung22-Sapphire IAnswer
22-Sapphire I
April 1, 2016

Uploaded file would only be a snapshot.

if you have something that is updating the XML file continuously, if you can, you could post the incremental updates to Thingworx using either the Edge MicroServer or the REST API