AutoCAD Inventor :: ILogic Assembly Has Double User Request At Inserting In Assembly
Sep 18, 2012
We have an iLogic assembly with to parts in it. Maybe to cylindrical parts. The iLogic rules should do the following.
1. Start a Rule after open document.
2. This Rule starts a Rule in the first cylindrical component.
3. This Rule ask the user for a diameter.
4. The assembly gives this new parameter value to the second component
5. Then the assembly calls another rule in the second component to change it with the new parameter
Everything is working fine when the following combinations are taking place:
1. I open up the assembly out of vault or from a local drive or an accessible server drive
2. I insert the assembly as sub assembly in another assembly from a local drive or an accessible server drive
It don't work with the following situation:
- I insert the assembly as sub assembly in another assembly out of vault
Then the user becomes the dialog "Choose a diameter" twice.
I don't know why, but I have the idea it has something to do with the functionality of inventor to insert a component more than once. If you insert a component in an assembly Inventor gives you the opportunity to add more than one occurence after each other.
change that behaviour? Maybe a switch to change that inventor "add more than one occurence" behaviour.
View 1 Replies
ADVERTISEMENT
Nov 9, 2011
I want to be able to control the location/position of a component in an assembly. This is easy enough through the iProperties/Occurrence tab and then adjust the location of the X,Y, and Z offsets. Is this possible using iLogic? I have been unable to find a function to access via iLogic. Ultimately I am trying to translate a component about an axis not a pattern.
View 1 Replies
View Related
Jan 3, 2012
I created a Ipart with like 14 different configurations now it operates smoothly within the part. Now once i insert it into a assembly it wont let me chance the configuration. I heard there was a problem like this but i thought it was only when you insert a part into a assembly and change it into a ipart while its still within a assembly.
Now my part never was in a assembly. Ill upload it and let me know if you have the same issue. Once i drop the part it doesn't give me the option to choose a configuration and when i click the configuration in the itable it still doesnt change it. Now this is only within a assembly.
View 8 Replies
View Related
Feb 3, 2013
If I nead to insert a Part a many times in an assembly... let's say fifty times.
The only way I know is to copy past fifty times (then I place them with the constraints neaded).
The rectangle or cicular array can't be used since they a realy in different places.
But is there a fastest way to insert the Part fifty times in the assembly, instead of copy paste?
View 3 Replies
View Related
Sep 14, 2012
I've been out of the programming game for a few years. But, using the sample code to place a part or assembly in an assembly by placing it with the mouse should be possible in VBA.
View 1 Replies
View Related
Feb 13, 2005
When I am inserting in an assembly two parts with I-mates and the name's of the I-mates are not matching they are acting of the name's are matching. So the two parts are constraint with the not matching I-mates.
View 7 Replies
View Related
Apr 1, 2003
I have a part file ("part1.ipt") that has a user parameter called "Height". When I open this file as a part document, I can modify the "Height" parameter to change the height of the part. This functionality works great:
Set oPartDoc = oApp.Documents.Open(sPartFileName, True)
Set oParameters = oPartDoc.ComponentDefinition.Parameters
'change part height to 30 cm
oParameters.Item("Height").Expression = 30
Now, I am wanting to add this part to an ASSEMBLY document, then change the parameter to 30, but have been unable to do it.
I have this so far:
Dim oAsmCompDef As AssemblyComponentDefinition
Set oAsmCompDef = oApp.ActiveDocument.ComponentDefinition
Dim oOcc As ComponentOccurrence
Set oOcc = oAsmCompDef.Occurrences.Add(sPartFileName, oMatrix)
After I add all the parts, I highlight a part in the assembly pane, I click on FxParameters but I don't see the User Parameters for the part. Are the User Parameters not available when a part is placed into an assembly?
This assembly will have multiple parts added from the same file name, but the "Height" parameter needs to be modified for each occurrence.
View 5 Replies
View Related
Jan 7, 2014
I create an IDW view of a subassembly by inserting the parent assembly, make it a non-associative view, then turn off visibility of unwanted subassemblies. When later working in the model and adding a part to one of the non-visable sub-assemblies, that part becomes visable in the IDW views in which the subassembly was non-visable, requiting me to edit all veiws in which the subassembly was non-visible. This can be quite a number of instances. Is there a way to prevent this?
I may have a more fundamental workflow problem: I create assemblies composed of subassemblies that need to be detailed sperately. I have found that in order to correctly create a structured BOM and to have the ballon lables to correspond to the structured BOM, I create the drawing views as described above. If I would just insert the subassembly to detail it, I don't understand how to get it to relate the balloon labels in the subassembly view to my master BOM.
View 6 Replies
View Related
Aug 26, 2013
I am trying to make a dxf from each sheet metal part in an assembly with ilogic: (I have cut and and paste different codes from this forum in an poor attempt...)
Sub Main
Dim oApp As Inventor.Application = ThisApplication
Dim oAssy As Inventor.AssemblyDocument = oApp.ActiveDocument
For Each oSubDoc as Inventor.Document In oAssy.AllReferencedDocuments
If oSubDoc.DocumentType = kPartDocumentObject Then
Dim oPartPropset As Inventor.PropertySet = oSubDoc.PropertySets("Design Tracking Properties")
Dim oPartParam As Inventor.PropertySet = oSubDoc.PropertySets("Inventor User Defined Properties")
[code].....
View 2 Replies
View Related
Jun 1, 2011
I wish to set the properties of an assembly using i Logic. I have the values of the properties in a part that is in the assembly. I wish to pass those values from the part to the assemblies i properties. I tried using the following code, but it gives an error saying it can not find the document "MyAssy.iam"
iProperties.Value("MyAssy.iam", ThisDoc.Path, "Part Number")=AssyNo
I'm not even sure that this is the way to do, but it's the only way I could think of to try.
View 9 Replies
View Related
Oct 26, 2012
I got here on in my templates, two types of weight - net and gross. I've changed the main property MASS of each PART to be the GROSS weight, so when i have one assembly i always get the total gross weight.
And when i wanna get the NET, I open the BOM, show the proper column with this net weight and then export do XLS to sum all of then..
Now the doubt is, to get the things easier, is there a way to put some code in the assemblies, that could sum all the properties "X" from each part and sub assembly to get the total net weight ?
View 7 Replies
View Related
Oct 3, 2011
I am very new to this whole concept of having ilogic based rules to drive your part design. I have even gotten as far as creating a ipart and having ilogic rules be able to suppress, unsuppress, change values and dimensions using ilogic rules. I now want to be able to use ilogic rules to drive some of the various(yet similiar) assemblies that I create all the time.
For instance, If I have just a flat plate as the base component with a shaft welded to it that varies in length for my assemblies. Since the shaft varies in length, I went ahead and created iparts for all the lengths of the shafts. I can manually change which shaft I want represented in the assembly, but I would like to to know how do I get Ilogic to place the different shafts based on user parameters???
I've looked into component place iparts, but can't seem to get the code to work. The list of iparts tree within the model doesn't pop up in the model tab in the ilogic rule, only the base component.
View 1 Replies
View Related
Jul 25, 2012
How to run iLogic Rule which I created for .ipt file in assembly?
As I have a myPart.ipt file with iLogic Rules which could create part1.ipt, part2.ipt, ..... (hundreds of them).
Now, I want creats iLogic Rule in myAssembly.iam to run the iLogic Rules in myPart.ipt in order I could create correct .ipt file to be used in myAssembly.iam.
View 4 Replies
View Related
Jul 26, 2012
I have the same ilogic part placed in the same assembly, and i am trying to drive two different configurations of the same part and when i apply the configuration it changes both of the parts but to only one of the configurations.
Is there a way to drive them seperately even though they are the same part.
View 5 Replies
View Related
Nov 29, 2010
My task consist in exporting a BOM of an iLogic assembly.
Is any way to get an accurate BOM of other LOD other than the master. If so, is it only available in certain Inventor releases?
I am trying to accomplish this through API, but I get error when in different LOD than master. iLogic assembly has some parts suppress thats why we need to create a new BOM.
View 9 Replies
View Related
Jul 1, 2013
I have a parent assembly that contains multiple sub assemblies, two of which need to synchronize with each other.In the parent assembly, I have created a user form that controls the sizes and quantities of all the different sub assemblies.
Sub assembly 1 contains a bracket for supporting 4 rows of pipes.Based on the width selected from the main parent assembly, the length of this bracket can vary.
The spacing of the 4 mounting positions is also determined from the length of the bracket.Sub assembly 2 is an assembly containing all the pipes.The pipes are spaced apart to suit the bracket using a component pattern, and it is this distance that I want to control from the parent assembly.This is just one of the basic scripts I've tried.
Pipe_Spacing=Parameter("SubAssembly1:1", "Pipe_Spacing_A")
Parameter("Piping assembly:1", "Pipe_Spacing_B")=Pipe_Spacing
Pipe_Spacing_A is the spacing of the bracket
Pipe_Spacing_B is the component pattern in the piping assembly
Pipe_Spacing is the parameter in the parent assembly to be driven by the bracket parameters.
I have very little iLogic experience & have being learning as I go along with this project.My best guess is that the code can't loop back on itself. On a slightly different note, I have also noticed that the sub assemblies don't update properly.
If I adjust the width to X and regenerate the model, some of the sub assembly updates. To fully update, I have to go back into the user form, change the size to Y & then change it back again to X and then regenerate.
View 1 Replies
View Related
Feb 24, 2013
I'm working on Autodesk VBA, and I'm trying to get user input on which vertex to use for a constrain. I want to make a macro that can go into part edit, allow user to select a vertex, and then automatically set up the constraint. Initially I wanted to do this in a single macro, using this short piece of code
while oSelectSet.Count <>1
DoEvents
Wend
While this worked when run directly from VBA, if I call it as a macro in Autodesk itself, the DoEvents doesn't seem o work because I wasn't able to make any selection at all. I googled and it seems like this is just how macros are.
So I split the code into a 2 subs and a function (as attached), and put them into separates rules that I call using a form in Autodesk. The first sub "Meta1Pin1_1" works, then I would select a vertex in edit mode. But when I go ahead and call the second sub "Meta1Pin1_2", I get the error message that I created which says no vertex is selected. But if I select a vertex and call the second sub again, it will work.
So I've been trying different things and I realize that every time when I first call the second sub, my selection is erased teh moment it goes into the sub. But, for some unknown reason, the selection will remain when I call it the second time. I can't figure out what exactly happened between the first and second call of the same sub, that allowed the selection to remain.
' prepares assembly for user input by grounding bones and going into part edit
Public Sub Meta1Pin1_1()
Dim oDoc As AssemblyDocument
[Code]....
View 2 Replies
View Related
Nov 19, 2012
I'm now having an issue accessing the features in an assembly, the error message is attached and the following is the relative code.
The error line is between the 2 Test Messages:
'Create a Component Definition relative to the Part Document
Dim oFeature As Features
Dim oAssembly As AssemblyDocument
oAssembly = oCompOcc.Definition.Document
MsgBox("Test 1")
'Cycle through all features in the Part
For Each oFeature In oAssembly.ComponentDefinition.Features
MsgBox("Test 2")
View 3 Replies
View Related
Oct 27, 2013
Is it possible to change a normal assembly into a weldment assembly through iLogic?
View 4 Replies
View Related
Jul 25, 2012
Before using iLogic, I created lot of iAssembly and iPart. I could change iPart factory member when I need in iAssembly.Now, I want to move everything to iLogic.
how could I change the part by iLogic code?
For example:
I generated "Part1.ipt" and "Part2.ipt",...... (I have hundred of member)
In my assembly, sometimes, I need use Part1.ipt, sometimes I need use Part2.ipt.
Which is the iLogic Code I should to use?
Inventor 2009, WIN XP.
Autodesk Inventor Professional 2013 (64 Bit) SP2
Windows 7 Professional Service Pack 1
Intel(R) Xeon(R) CPU E5645
12.0 GB Memory
View 9 Replies
View Related
Mar 6, 2012
I need to be able to pick a face on a part in an assembly inside a iLogic rule. How can I set up the events to suspend the code to have the user pick the face?
View 6 Replies
View Related
Jan 9, 2012
I have made an iLogic external module who copy the iProperties from an Excel files, when i open the module from the *.ipt file il works perfectly. But i need this function from *.iam files.
Something like this: when i click with right button in one selected part of assembly i can open the module only for this part and when i save it save the change for all modify part of *.
View 1 Replies
View Related
Apr 4, 2013
I want to use I logic to adjust an assembly constraint based on T/F value passed from a master sketch.
I have passed the paramater T/F and/or a user paramater as described in this thread using link (neet trick).. but when the code fires it only works on the true application and not the false.. if i open the rule and then close it the update button becomes available and when updated the false condition updates sucessfully. I have tried just re-running the rule to no avail. It seams that the only way I can get it to triger a false condition is to open the rule... close it and update.
If Parameter("iTrigger0101000") = 1 Thend37_Header1 = -.25 ind34_Header2 = -.25 inElseIf Parameter("iTrigger0101000") = 0 Thend37_Header1 = -.25 ind34_Header2 = 0.0 inEnd If
View 2 Replies
View Related
Jan 9, 2014
I would like to count all my parts in the main assembly and assign that amount to each part.
Example: Main assembly has: 10 Parts A and 5 Parts B. I would like to run a rule that "sends" that "10" to Part A.ipt and the "5" to Part B.ipt
I would like to assign it to iProperties.Status.Status. I start to understand iLogic more and more but it is nice to get a little boost in the right direction.
View 4 Replies
View Related
May 10, 2012
Change pattern ilogic. How do you change the distance and quantity in an assembly with ilogic?
It is simple in a part but in an assembly the parameters and equations do show.
View 1 Replies
View Related
Apr 23, 2013
The setup is: I have a rule which first gets a number of user parameters via input boxes.This rule then runs a number of other rules, using:
iLogicVb.RunRule("Rule 1")iLogicVb.RunRule("Rule 2")iLogicVb.RunRule("Rule 3").Each of these rules control parameters, part/feature/constraint suppression etc. in the top level and subassemblies/parts based on the previously obtained user parameters.
All the rules have the 'Don't run automatically' option selected, so all should only run as intended when I manually run the first rule.When I run the first rule, I enter all the parameters, and the subsequent rules run.The problem is, the suppression states etc. in the subassemblies/parts do not update.
Looking at the parameters dialog box after the rules have run, all user parameters have updated with the new values.If I run the first rule again the subassemblies/parts update correctly.
It appears that the rules that control the suppression states etc. of the subassemblies run using the initial values of the user parameters, i.e. the values as they were before the user input is obtained, rather than the new values.This is confusing me, as the code is structured as follows:
user_parameter_1 = InputBox("User Parameter 1", "Input", "xx")user_parameter_2 = InputBox("User Parameter 2", "Input", "xx")iLogicVb.RunRule("Rule 1")iLogicVb.RunRule("Rule 2")
View 2 Replies
View Related
Oct 6, 2011
I Created an iLogic Rule that sets up some parameters.
I want to Automatically opens each and every Part in my assembly, run this Rule, and then save it without me having to do so manually.
View 8 Replies
View Related
Jul 26, 2012
I need to modify all the ipt in an assembly, but I don't kow how many ipt I have, and I don't know the name. Can I have with iLogic the list of all the ipt used in the assembly ? For example, to modify the Part Number in all the components.
The code should be like this :
For All component in Assembly
...
...
Next component
View 3 Replies
View Related
Oct 26, 2011
Is there a way to set an assemblies bill of material setting to reference through iLogic?
View 3 Replies
View Related
Oct 25, 2011
I'm using I-logic to suppress components in an assembly. I've attached a screenshot with 3 suppressed components.
In the browser the parts are suppressed but in the BOM (items 6,7,9) they are not. Is there a piece of code for this?
View 5 Replies
View Related
Dec 30, 2013
Im after programmatically mating 2 components together in an assembly. My stages are as follows:
1)Create New Assembly
2)Add .ipt's
3) One-by-one, mate all the parts together (each part has a plane named "WPStart" and "WPEnd". In each part im after the WPStart being flush mated with the WPEnd of the 2nd part - see image attached. In addition I would like to mate al the XZ planes in each of the parts fluch together and likewize the YZ planes.
3) Mate the parts together
Dim FlushConst As FlushConstraint
FlushConst.AffectedOccurrenceOne = oAssyDoc.ComponentDefinition.Occurrence.Item(1).Workplanes.ItemByName("WPStart") <--------
FlushConst.AffectedOccurrenceTwo = oAssyDoc.ComponentDefinition.Occurrence.Item(2).Workplanes.ItemByName("WPEnd") <--------
View 2 Replies
View Related