"Application Development Tips & Tricks" guide is not outputting results
- September 20, 2019
- 1 reply
- 988 views
I am following the example in the "Application Development Tips & Tricks" guide(https://developer.thingworx.com/en/resources/guides/application-development-tools-tips-tricks), but the result data does not come out normally. What's wrong?
Is there a way to put data into ThingTemplates ["LinePartTemplate"]?
The code is shown below :
var params = {
infoTableName : "InfoTable",
dataShapeName : "LinePartDataShape"
};
dataShapeName:STRING):INFOTABLE(LinePartDataShape)
var result = Resources["InfoTableFunctions"].CreateInfoTableFromDataShape(params);
var partList = ThingTemplates["LinePartTemplate"].GetImplementingThingsWithData();
var tableLength = partList.rows.length;
for (var x=0; x < tableLength; x++) {
var row = partList.rows[x];
if(1000 > TemperatureThreshold){
var newEntry = new Object();
newEntry.PartName = row.PartName; // STRING
newEntry.PartTemperature = row.PartTemperature; // NUMBER
result.AddRow(newEntry);
}
}

