Cancel
Showing results for 
Search instead for 
Did you mean: 

Updating Store parts in inventory table

Builder
Builder

Hello Everyone,

                    I have small doubt regarding parts in the store.

I want to update in a table file whichever the parts are coming to the store (including their time and quantity).

How can I write a program for this?

My store receives 7 different parts at different times and with different quantities.

Could anyone help me please.

Thank you very much

 

Regards

8 REPLIES

Re: Updating Store parts in inventory table

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor
do you want to record each part or the total number of parts for each part type ?

Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Updating Store parts in inventory table

Builder
Builder

I want record it for each part type.

Thank you 

Re: Updating Store parts in inventory table

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor
than is the easiest way to use a tablefile with active row-index
Write in the row index all names of your parts. Format the first column as integer.
Then you need only a very simple entrance control in the store:

inventory[1,@.name]:=inventory[1,@.name]+1

You need to delete the values of this table in the init-method (inventory.delete)
Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Updating Store parts in inventory table

Builder
Builder

Thank you Steffen

It is working perfectly.

 

I have one more doubt regarding sub frames.

I have 7 sub frames in a main frame but i want activate only one or two frames at a time. for example i want to start frame1 then after 3 min. frame 2 and remaining frames should remain silent.

Re: Updating Store parts in inventory table

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor

How do you want to start them?

Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Updating Store parts in inventory table

Builder
Builder

I tried to stop the eventcontroller by writing 'models.frame.eventcontroller:=stop' in each frame but i couldn't place eventcontroller in sub frames.

I am attaching my model. please check it once.

the 7 sub frames produces 7 different variants. But based on the customer order i want only 2 variants.

Thank you very much

 

regards

gopi 

Re: Updating Store parts in inventory table

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor
just set the start of the sources to a very big value e.g. 10000 days, something beyond your experiment length, then the subframe keeps silent, the same you can do with start-times
Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Updating Store parts in inventory table

Builder
Builder

Thank you very much Steffen it helps me alot.