cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can change your system assigned username to something more personal in your community settings. X

local binding through script

davidcor
1-Visitor

local binding through script

I'm trying to pass the name of "TrackerThing" to a service on a "CarThing" to bind the location property of the tracker to the car.

var params = {

    propertyName: "location" /* STRING /,<br>    sourceThingName: trackerName / STRING /,<br>    sourcePropertyName: "location" / STRING */
};

me.SetLocalPropertyBinding(params);

The service runs with no effect. In the app log I see this error: "Invalid service name: GetRemoteMetadata"

I can perform this action manually.

2 REPLIES 2
adam11
7-Bedrock
(To:davidcor)

Hi David,

I've created a case (#12119975) in our PTC eSupport Portal for this issue and you should have received an email with instructions for viewing it.


Regards,

Adam



fmanniti
10-Marble
(To:adam11)

Sorry, I have the same issue with that function.

I have this code

var thingName = "DS-TH_prova";

var remThingName = "DS-RemTH_prova";

var paramsTH = {

    name: thingName,

    thingTemplateName: 'DeviceSimulatorTemplate',

    tags: tags

};

Resources["EntityServices"].CreateThing(paramsTH);

var paramsRemTH = {

    name: remThingName,

    thingTemplateName: 'DeviceSimulatorRemoteTemplate',

    tags: tags

};

Resources["EntityServices"].CreateThing(paramsRemTH);

var props = {

    propertyName: 'PropNum_4', //<<<<Property in Remote thing

    sourceThingName: thingName,

    sourcePropertyName: 'Temperature' //<<Property in thing

};

Things[remThingName].SetLocalPropertyBinding(props);

but it won't work.

Did you solve it a the end?

Announcements


Top Tags