question

10Dulkar avatar image
0 Likes"
10Dulkar asked 10Dulkar answered

row index of global table

how can i pull the name of row index in a script. I am using the following, please check and let me know if this is right or there is some other command to pull the value.

Table:

this is the example table where i have assembly names on index rows and process attributes on the columns. I want to pull the name of assembly based on which step in process it is. so i am using the above command.


Index rows below ProcessTime
Assembly 1
10
Assembly 2 20
Assembly 3 5


string AssyName= Table("TableName")[token.sequenceNumber][0]--I am using 0 to pull the index column number.

@Matthew Gillespie

FlexSim 21.2.2
globaltableflexsim 21.2.2
5 |100000

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

10Dulkar avatar image
0 Likes"
10Dulkar answered

Never mind....I found it. Its getRowHeader() function to get the header values.

5 |100000

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

Jordan Johnson avatar image
0 Likes"
Jordan Johnson answered 10Dulkar edited

In FlexSim, global tables can have a row header. Take this table:
1631127027824.png

This table has a row header and a column called Process Time. You can use code like this to get the Process Time based on the row header:

Table("MyTable")["Assembly 2"]["ProcessTime"]



1631127027824.png (3.7 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.

10Dulkar avatar image 10Dulkar commented ·

thank you for your answer, but i need the row index value not the process time. otherwise i know how to pull the values from the table. Do you know how can i access the row index value. Check out the code i put. can we use 0 to pull the row index value.

string AssyName= Table("TableName")[token.sequenceNumber][0]--I am using 0 to pull the index column number.

I want to pull assembly name not the process time.

0 Likes 0 ·