Page 1 of 1

ExcelActiveX atom

Posted: Monday 25 April, 2016 - 17:02
by GroepT
Hi,

We have a question concerning the ExcelActiveX atom.
We want to read the data in the Excel-file as inter-arrival times in the source atom.
In total, we have 112 data (so 112 rows and 1 column).
Now we say in the source atom in the inter-arrival time field that: MyTable(1,1) and MyTable is the alias name for our table. However, when we run the model, the source creates products according to the first row only, and repeats this 112 times. So it takes always the same inter-arrival time. How can we take all 112 different times as our inter-arrival time?

Kind regards

Re: ExcelActiveX atom

Posted: Tuesday 26 April, 2016 - 08:53
by HarryBunnik
Ha,

When you use MyTable(1,1) then it's indeed only the 1st row that is used. You'll have to find a way to update the row number based on what is handy for you.

You could use something like Input(c) instead of 1, which simply counts how many products have entered the sink. That way you automatically update this inter-arrival time. Another way may be to use dUniform(1, 112). Here you pick a random integer number between 1 and 112.

Cheers and success,

Harry

Re: ExcelActiveX atom

Posted: Tuesday 26 April, 2016 - 15:17
by GroepT
Hi,

Thank you for the fast replay.

I used Input(c)+1 instead of 1 in the "inter-arrival time" box and in the "time till first product" i put MyTable(input(c),1) and it worked as I wanted.

Thanks again,
Kind regards