question

Gui Vaccaro avatar image
0 Likes"
Gui Vaccaro asked Jason Lightfoot answered

Bug - Parameters, On Set event is triggered before value changes

Hello,

In the Parameters tables the OnSet trigger is fired at the first OnKeyDown, hence before the value is changed. As a consequence, on set code is executed mistakenly. This becomes worse if one uses the parameter as "Option". In this case, to access the options, a double-click is necessary, firing the event before any option appears. On that note, why would a double-click be necessary if there is already an "Edit Mode" feature in the parameters table as for other dashboards: when not in edit mode, the simple drop-down should suffice.

1737990502433.png1737990534245.png

Thank you for any clarification.

FlexSim 25.0.2
bug reportparameterson set
1737990502433.png (128.5 KiB)
1737990534245.png (98.6 KiB)
5 |100000

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

1 Answer

Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered

I normally would add the condition if (isReset) which gets me through any issues since I want to reset the model when making such changes. I agree the timing /sequence and population of old/new values has not always matched what might be expected and I believe the developers are aware of this.

· 3
5 |100000

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

Gui Vaccaro avatar image Gui Vaccaro commented ·
Hi, @Jason Lightfoot ,

thank you once more! I will try it again, but it would be great if the interface worked better in this case. Having the trigger set before the change happens and dealing with two drop downs increases the complexity way too much.


0 Likes 0 ·
Jason Lightfoot avatar image Jason Lightfoot ♦♦ Gui Vaccaro commented ·

Noted - I've linked this post to the issue in our tracker - if there's some movement relating to this we may get an update in this post. Has the isReset flag allowed you to get past the issue for now?

1 Like 1 ·
Gui Vaccaro avatar image Gui Vaccaro Jason Lightfoot ♦♦ commented ·
Absolutely. Thank you.
0 Likes 0 ·