question

Maryam H2 avatar image
0 Likes"
Maryam H2 asked Maryam H2 commented

Determine flowtime by referring to a Global Table

Hi,

How I can refer a flowtime in Create patient to a global table by defining the gender of each person in a separate column?

I created a Global Macro to refer to the column and seems that doesn't work.

Also, I do not know in the "Row" by Looking up from a Global Table, should I refer to the token.Row or token. Name (Name is another label that I created for each person).

Attached is the simple model and the error I'm getting when run the code.

Thanks

sample_model_office_1.fsm

FlexSim 22.1.2
flowitemlabelcreate person
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

·
Kavika F avatar image
0 Likes"
Kavika F answered Maryam H2 commented

Hey @Maryam H2, it seems the first person in the table is created correctly at 8AM, but the second person at 8:30AM throws an error. The error occurs at the Create Patient activity when referencing your People Parameters global table. When clicking on the 1st cell under Gender, it shows a little script icon next to it:

1656538807559.png

However, the other cells under gender did not. I realized that the 1st cell had a different data type than the other cells - it was FlexScript Data while the rest were not. After changing all the cells to have the FlexScript Data type, the program ran smoothly.

To change the data type of a cell, highlight the cells you want to change, right click, hover over Assign Data, then select the type you want.

1656538942579.png

Hope this helps!


1656538807559.png (25.7 KiB)
1656538942579.png (64.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.

Maryam H2 avatar image Maryam H2 commented ·
Ahh, you're right! Thanks @Kavika F
1 Like 1 ·

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.