question

Derek Flannery avatar image
0 Likes"
Derek Flannery asked Sam Stubbs commented

How to output the value of a label when it changes?

I am working on a model where I want to, either through a dashboard or output to a note pad file, the values of a label every time I change it.

There may be an easy way to use code to output (because I use a message to a source to change the label value). I have the value it changes to stored in a local variable in the message trigger, but to actually record that value without going through a messy global table setup is not ideal.

Thanks for the help.

FlexSim 16.2.1
labelsoutput
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Sam Stubbs avatar image
0 Likes"
Sam Stubbs answered Sam Stubbs commented

It sounds like what you want is a tracked variable. You can use a tracked variable to get the changes to a value/variable. In your logic, wherever you change the label, save it's value to the tracked variable. And then you can add that tracked variable to a dashboard widget and it can show you the previous values or average value etc of the tracked variable. Is this along the lines of what you were looking for?

· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Kari Payton avatar image
0 Likes"
Kari Payton answered Ben Wilson edited

@Derek Flannery I had a question before that may be similar to what you are trying to do. Check this post:

https://answers.flexsim.com/questions/27025/is-there-a-way-to-display-the-average-value-of-a-l.html

5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.