Forum Discussion
I can see issue is fixed. But my question here is why cant we call this property
def wildvalue = instanceProps.get("wildvalue")
in Collection Script?
Because with batchscript, the script runs for all instances. Which instance's wildvalue did you expect back? You can only do instanceProps.get("wildvalue") on script, not batchscript.
- Anonymous3 months ago
I believe there is a way to grab from the deviceDatasourceProps the list of wildvalues, but i haven't been able to relocate the code where i saw that done.
It would be nice if someone from LM who knew how to do it chimed in here. Maybe someone from the ME team...
- skylaurman3 months agoEmployee
Here is a way to get a list of the wild values:
def listOfWildValues = datasourceinstanceProps.values().collect { it.wildvalue }
Here is a way to do as you wish with the wild values:
datasourceinstanceProps.each { instance, instanceProperties -> instanceProperties.each { it -> def wildValue = it.wildValue // Do something with wild value } }
- Anonymous3 months ago
This is the right answer. Could someone at LM please put in a DOC ticket to get this published into the support documentation or the dev guide?
Related Content
- 10 months ago
- 10 months ago
- 7 months ago
- 2 months ago