Flexscript Error about Decision Point pick option

Flexscript Error about Decision Point pick option

ozawa_shinya
Advocate Advocate
202 Views
8 Replies
Message 1 of 9

Flexscript Error about Decision Point pick option

ozawa_shinya
Advocate
Advocate

[ FlexSim 23.0.8 ]

Hi,

An error occurs if the value is "If" in the Set Label of the Decision Point pick option.

Originally, what kind of operation is it intended to set?

This also happens on FlexSim 2022.0.11.

Thanks in advance.

1691025539438.png

0 Likes
Accepted solutions (1)
203 Views
8 Replies
Replies (8)
Message 2 of 9

joerg_vogel_HsH
Mentor
Mentor

Set a string in double quotation marks!

“if“ is a correct value

0 Likes
Message 3 of 9

ozawa_shinya
Advocate
Advocate

I understand that strings must be enclosed in double quotes. As in this example, it is not kind to set the default value and cause an error. If the pick option assigns a string, the default value should be a double-quoted string. But from the name "If" I can't imagine it being a pick option for assigning strings.

Message 4 of 9

joerg_vogel_HsH
Mentor
Mentor
@Jason Lightfoot, please, can you check this list of suggested inputs for a label value field in Control Point On Arrival trigger. Thank you.
0 Likes
Message 5 of 9

logan_gold
Community Manager
Community Manager
Accepted solution

This looks like a bug. I'm guessing the If picklist option should not be there. I'll let the developers know.

0 Likes
Message 6 of 9

ozawa_shinya
Advocate
Advocate
Thank you for yoour information.
0 Likes
Message 7 of 9

jason_lightfootVL7B4
Autodesk
Autodesk

I see Logan has answered - it looks like this 'If' option was erroneously added in the 2021 version and exists in the options for both "set Label" and "set label and color".

Control Points have only had the option to add triggers in quick properties since 21.2 and they have never had a complete picklist that I can tell - only recently was Code Snippet added. Are you saying they should be added?

0 Likes
Message 8 of 9

ozawa_shinya
Advocate
Advocate

It is possible to directly edit the code that is executed when the trigger is called, so I don't think it is necessary to add a new Code Snippet to the options for both "Set Label" and "Set label and color".

0 Likes
Message 9 of 9

Matthew_Gillespie
Autodesk
Autodesk

@Shinya O This issue has been fixed in 23.0.11 and 23.2.1 released today.

The 'If' option was being added by an automated mechanism for adding all variable in the code header to the list of options. However it was incorrectly identifying a comment in the code as a variable.



Matthew Gillespie
FlexSim Software Developer

0 Likes