Skip to main content
1-Visitor
December 21, 2018
Solved

State-based Images in Tree Widget

  • December 21, 2018
  • 1 reply
  • 2025 views

Hello!

 

I've searched the forums to no avail for this - apologies if I missed it. I am attempting to figure out if there is a way to include state-based images for icons in the tree widget in Thingworx. Essentially we want to have a little red or green circle to indicate in the navigation tree if there is an issue with any machines at a location. Is there a way to do this that I'm simply not able to figure out? I've attached an image as an example of what I'm trying to do. The colored dots would be icon images. 

if this is not possible, is there a way to do state-formatting on the text in the tree? 

 

Thanks!

Best answer by mneumann

Hi @rweller

I think this might be done via a State Definition.

 

  • Create the State Definition based on the Property and its values that trigger the green / red icons.
  • Then assign a Style to them where the Icons are a Media Entity (image).
  • In the Tree you can then set the Tree Formatting to the State you defined earlier, it could e.g. be based on a Boolean property that uses a true (green) and false (red) state

Cheers,

Michael

1 reply

mneumann16-PearlAnswer
16-Pearl
December 21, 2018

Hi @rweller

I think this might be done via a State Definition.

 

  • Create the State Definition based on the Property and its values that trigger the green / red icons.
  • Then assign a Style to them where the Icons are a Media Entity (image).
  • In the Tree you can then set the Tree Formatting to the State you defined earlier, it could e.g. be based on a Boolean property that uses a true (green) and false (red) state

Cheers,

Michael

Support
December 31, 2018

Hi @rweller.

 

If the solution provided by @mneumann answered your question, please mark it as the Accepted Solution for the benefit of others with the same question.

 

Thank you for using our Community!

 

Regards.

 

--Sharon