question

Daniel Martinez avatar image
0 Likes"
Daniel Martinez asked Jason Lightfoot commented

Error in the wait for event

I do not why I cannot select "item" in the entering item option. 1705309738554.pngThe next error appears:

Flexscript Error MODEL:/Tools/ProcessFlow/OpportunityCombiner/Wait for Event~2>variables/events/1/objRef Line 5 syntax error, unexpected identifier, expecting ')' or ','Could not finish parsing because of previous errors.

Here you have the model (2022 version)

2022 ASSEMBLY.fsm

FlexSim 22.1.4
combinerwait for eventvariable
1705309738554.png (30.8 KiB)
2022-assembly.fsm (79.2 KiB)
· 1
5 |100000

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

Jason Lightfoot avatar image Jason Lightfoot ♦♦ commented ·

Hi @Daniel Martinez, was one of Iago MF's or Joerg Vogel's answers helpful? If so, please click the "Accept" button at the bottom of the one that best answers your question. Or if you still have questions, add a comment and we'll continue the conversation.

If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always comment back to reopen your question.

0 Likes 0 ·

1 Answer

Joerg Vogel avatar image
0 Likes"
Joerg Vogel answered Joerg Vogel commented

You can select from this menu list label names that you have already used somewhere else in your process flow to assign them at tokens. If you haven't assigned label name "item", then you cannot choose it.

You can check it in a new model. You will see that this list is empty at the beginning.

· 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.

Daniel Martinez avatar image Daniel Martinez commented ·
So what should I do to fix the error?
0 Likes 0 ·
Felix Möhlmann avatar image Felix Möhlmann Daniel Martinez commented ·

By not just blindly copying words you see in another model into a field without knowing its meaning. ;-)

The object field expects that the entered value is a pointer to an object. This could be a label on a token or as in this case, the instance object. In an Object Process Flow the instance object can be accessed through the parameter name current in just about any activity. You also copied the "(No Instance)" text into the field. So now it contains both an Object variable and plain text and as a result the compiler throws an error. You can see this more clearly when you look at the code of the field.

capture1.png

If you only type in current, the text in the field automatically changes to this:

capture2.png

Note that the text has turned purple to denote that this represents a pointer value.

So why does it say "(No Instance)" after current?

The value in parentheses is supposed to let you know which instance of the Process Flow you are currently looking at. "No Instance" meaning that this is the 'master' version of the Process Flow so to speak from which the individual instances are derived.

If you open the PF view of the OppCombine object you will see that the field now shows the name of the object whose PF instance you are looking at.

capture3.png

capture4.png

1 Like 1 ·
capture1.png (23.3 KiB)
capture2.png (5.5 KiB)
capture3.png (9.0 KiB)
capture4.png (5.2 KiB)
Joerg Vogel avatar image Joerg Vogel Daniel Martinez commented ·
@Daniel Martinez, instead of selecting a word, you can directly write into this field. If you think "item" is a good name as a label name then you can type this into the field by your keyboard.
0 Likes 0 ·