question

bcallaghan avatar image
0 Likes"
bcallaghan asked Jason Lightfoot commented

Custom Code for Entry Trigger

Trying to have a label be automatically created upon queue entry on a flowitem that timestamps the time a flowitem enters a queue. My code is returning an error but unsure what is wrong. Help would be appreciated. Thanks! Tried commenting out some things to see if it would fix it but no luck.

1700498214798.png

FlexSim 21.1.5
labelscustom codetriggerupn entry
1700498214798.png (17.5 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 @bcallaghan,

We haven't heard back from you. Were you able to solve your problem? If so, please add and accept an answer to let others know the solution. Or please respond to the previous comment so that we can continue to help you.

If we don't hear back in the next 3 business days, we'll assume you were able to solve your problem and we'll close this case in our tracker. You can always comment back at any time to reopen your question, or you can contact your local FlexSim distributor for phone or email help.

0 Likes 0 ·

1 Answer

·
Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered Jason Lightfoot commented

Use the new syntax:

item.ArrivalTime=entryTime;

Or use the pick option to set a label value and use its template to enter values.

· 4
5 |100000

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

bcallaghan avatar image bcallaghan commented ·

@Jason Lightfoot, should I just replace line 10 with this? Or are you saying to this as my "value" within setting a label under the onEntry label trigger?

0 Likes 0 ·
Jason Lightfoot avatar image Jason Lightfoot ♦ bcallaghan commented ·
you can use that instead of the line using setlabel()
0 Likes 0 ·
bcallaghan avatar image bcallaghan Jason Lightfoot ♦ commented ·
Still not working for some reason.
0 Likes 0 ·
Show more comments

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

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