ATTENTION

This FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices.


flexsim.com

Go Back   FlexSim Community Forum > FlexSim Software > Q&A
Downloads

Q&A Using Flexsim and building models

  #1  
Old 02-05-2010
KelvinHo KelvinHo is offline
Flexsim User
 
Join Date: Jan 2008
Location: Hong Kong
Posts: 129
Downloads: 18
Uploads: 1
Thanks: 44
Thanked 23 Times in 7 Posts
Rep Power: 171
KelvinHo will become famous soon enough
Default Batch connection changes

Hi,

Another batch problem here,

i have 1000 conveyor A : A0001.....A1000
which already connectioned to 1000 combiner B : B0001....B1000

as I would like to connect a source from C as the container to the combiner B

As i use batch connection in connection GUI, the added connections would be set as the last input port of B, which means C would be the content but but container....

Is there is fast way to batch connect a item to be the 1st port of the target? thanks.

Regards,
Kelvin
  #2  
Old 02-05-2010
Tom David's Avatar
Tom David Tom David is offline
Flexsim User
 
Join Date: Aug 2007
Location: Schwaebisch Gmuend, Germany
Posts: 430
Downloads: 157
Uploads: 47
Thanks: 486
Thanked 450 Times in 233 Posts
Rep Power: 520
Tom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant futureTom David has a brilliant future
Default

One way could be to delete all the existing connections and first do the Source connections and redo all the other connections. Quite some work, I would think.

I would do the Source connections as you described. Now they should all be the last Input Connection on the Combiners.
Select all combiners (red box for selected objects).
Now run the following code in a script window:
// FOR ALL SELECTED (RED) OBJECTS IN MODEL
forobjecttreeunder(model())
{
// IF OBJECT IS SELECTED AND IF IT IS AN OBJECT
if(and(switch_selected(a,-1), getdatatype(a) == 4))
{
// POINTER TO INPUT CONNECTIONS
treenode Connectionsin = node(">connections/connectionsin",a);
// SET RANK OF LAST INPUT CONNETION TO ONE
setrank(last(Connectionsin),1);
}
}

This will switch the position of the last input port to the first input port of all selected objects.
__________________
tom the (A)tom: "We have solved our problems ... now we have to fight the solutions."
The Following 5 Users Say Thank You to Tom David For This Useful Post:
Steven Hamoen (02-05-2010)
  #3  
Old 02-05-2010
Brandon Peterson's Avatar
Brandon Peterson Brandon Peterson is offline
The Flexsim Consultant
 
Join Date: Jul 2007
Location: Salt Lake City, Utah
Posts: 382
Downloads: 29
Uploads: 6
Thanks: 192
Thanked 516 Times in 235 Posts
Rep Power: 490
Brandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant future
Default

Kelvin,

If you have n objects that all need to be connected the exact same way. You can connect the first object up correctly and then use the duplicate connections in the connection GUI to set the connections for the remaining objects.

Good Luck,
Brandon
__________________
thats not normal.
The Following User Says Thank You to Brandon Peterson For This Useful Post:
Steven Hamoen (02-06-2010)


Thread Thread Starter Forum Replies Last Post
PLC connection, positioning issues Stephan Seidel Q&A 13 04-08-2010 01:02 AM
Port Connection Problem Joe Allen Q&A 2 05-11-2009 10:56 AM
Batch production (Batch size for processor) Patrick Cap Q&A 12 03-27-2009 12:14 AM
How to recognize the task excuter by connection Sung Kim Tips and Tricks 2 06-11-2008 10:13 AM
how to send msg to another which do not have connection with the sender object KelvinHo Q&A 3 03-05-2008 04:28 AM


All times are GMT -6.
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Copyright 1993-2018 FlexSim Software Products, Inc.