AutoCAD Inventor :: ILogic - Skip Saving A Suppressed Component / Delete Suppressed Component
Aug 30, 2012
I have an assembly which has a few components suppressed.
My end results is another copy of the assembly (with copies of the all the parts) in another directory
Now i am able to create copies of un-suppressed parts using; (this allows me to SaveAs assembly components which are not suppressed)
DocumentsEnumerator = ThisDoc.Document.AllReferencedDocuments
And save a copy of the assembly using
ThisDoc.Document.SaveAs
I also added the fllowing snippet (which I am not sure what is does), but it does not work for me
Component.SkipDocumentSave = true
When I open the newly created assembly, I still see the suppressed components in the model browser
I want to either;
Skip saving the of the components in the model browser (i.e. the Assembly)
OR
Delete the suppressed parts in the Assembly, so that they do not save altogether
View 3 Replies
ADVERTISEMENT
Sep 20, 2013
How to modify the code below to delete suppressed parts in a pattern (entire pattern)?
Dim oComp As ComponentOccurrenceDim oComps As ComponentOccurrencesoComps = ThisDoc.Document.ComponentDefinition.OccurrencesFor Each oComp In oCompsIf Component.IsActive(oComp.Name) = False Then oComp.DeleteNext
Code works fine if there are single instances of the part. It throws a error when you have a suppressed pattern.
View 7 Replies
View Related
Jan 24, 2013
I have an assembly which includes lot of parts (*.ipt) or sub-assembly (*.iam). I have some ilogic rules to control to suppress or un suppress them.
Now for the released assembly, I want delete all suppressed components by ilogic rule.
View 9 Replies
View Related
May 7, 2013
I started with a huge ipart table which was created by a collegue who has now left. The factory was unmanageable as it had reached the maximum amount of columns and was running very slowly.
To combat this, I decided to split the table in half so that the ipart will become two iparts. I am now working on the first half...
A lot of features are unque to one or a few parts, so doing this enabled me to delete columns if all values in the columns matched after the table was halved.
I thought this would speed up the file but I have now realised I have a bunch of features sat in the browser than are suppressed in every member!
Is there any way to use ilogic or vba to run a script that will delete a feature if it is suppressed in every member?
Inventor 2013 Certified Professional
Autodesk Inventor Professional 2011
Windows 7 Enterprise, 64-bit
View 1 Replies
View Related
Feb 13, 2012
I have a iLogic assembly with some parts and sub assembly. I need to do a copy of this " Generator " to apply the result later in other assemblies. (something like a member of a ipart or i assembly).
Is there any way to do the copy the assembly to a new folder without the suppressed parts and subassemblies (wich are suppressed in the initial main assembly by iLogic rules)?
I tried to use "Pack and go" and "iLogic design copy", but they always bring the suppressed parts and assembly's, to the new folder and which i don't need to apply in the other assemblies.
View 1 Replies
View Related
Dec 26, 2013
Is there a way to work with parameters on a suppressed assembly using iLogic.Everything works fine, but when I suppressed a part ilogic rule give me an error: Parameter: The component named "xxxxx:1" was not found.
View 1 Replies
View Related
Jan 26, 2012
We are having an issue when we replace a component in Inventor Pro 2012. When we replace a component, the name in the browser does not update to the new component. We've even tried to close and re-open the Inventor assembly and that does not work. We end up manual double clicking the name in the browser and type in the new component name.
Inventor Product Design Suite Ultimate 2012
Dell Precision T7500 Workstation
Xeon Processor
16 GB of RAM
Nvidia Quadro FX 5800
Windows 7 x64
View 4 Replies
View Related
Jul 25, 2012
II need a way to tell if a component occurence is a virtual component.
I'm using a For Each loop to cycle through all of the components in an assembly, and if the component is itself an assembly to set the LOD to "Custom". I'm using the definition document descriptor object for this. It all woks fine until the loop comes across a virtual component which doesn't have a definition document, so I need a way to check if the component is virtual and needs to be skipped.Here's the
Option ExplicitImports Inventor.LevelOfDetailEnumSub MainiLogicVb.UpdateWhenDone = TrueDim doc As AssemblyDocumentDim oLOD As LevelOfDetailRepresentationDim oAsmCompDef As ComponentDefinitionDim oComp As ComponentOccurrenceDim oComps As ComponentOccurrencesdoc = ThisDoc.DocumentIf.
[code]....
View 2 Replies
View Related
Jan 11, 2013
I am trying to make port rims for pipes that can be swapped in and out of an assembly. However, the ports will all be different sizes and located differently so I need the cut to be part of the port rim component, but affect the entire assembly it is part of. I've been trying to get this to work for the better part of a day now,Here's a picture of what im talking about. I'm running Inventor 2008 by the way.
View 2 Replies
View Related
Jan 16, 2013
What I am trying to do is insert a part into an assembly file using iLogic. I basically want to mimic Inventor’s “Place” command using ilogic, maybe something like this:
oPath = ThisDoc.Path & ""
oFile = "File.ipt"
Component.Place(oPath & oFile, False)
View 1 Replies
View Related
Mar 1, 2012
How can I include component suppression in the idw views? I suppress a component in the ipt or asm, but it doesn't
disappear from the drawing views. Is there a way to carry this over to the drawing?
View 1 Replies
View Related
Dec 28, 2012
Is it possible to skip the small preview window and the parameters display when i place an iLogic component white the command Place iLogic Component.
View 1 Replies
View Related
Aug 12, 2013
I'm trying to play around with iLogic for creating dynamically dimensioned subassemblies. I've created my dimensioning rules that link to the parts I wish to change dimensions on.
Parameter("Bridge Spine:1", "BridgeLength")=Length
And I've tested this in the SubAssembly I've created and all appears fine. However when I go to insert the sub assembly into the main assembly I get the following error:
Parameter: The component named "Bridge Spine:1" was not found.
I've noticed that the new sub assembly has created new parts with the extension -01 on the end of each part (As expected) It appears that this link is being lost in the rule for the new sub assembly. i.e the rule is looking for Bridge Spine:1 instead of Bridge Spine-01:1
View 3 Replies
View Related
Apr 10, 2012
we are using level of details to suppress few components. when we are trying to take BOM for that level of details. we are getting the suppressed components also. is there any control we can do avoiding that suppressed component. I know if you make the BOM sequesnce to reference that wont come in BOM. but we need that file for other LOD.
View 9 Replies
View Related
Nov 7, 2013
I am trying to set the appearance of sub-components in an assembly using iLogic.
Dim oDoc As Inventor.AssemblyDocument = ThisApplication.ActiveDocument Dim oCompDef As Inventor.ComponentDefinition = oDoc.ComponentDefinitionDim oCompOcc As Inventor.ComponentOccurrence 'parts in the assemblyFor Each oCompOcc In oCompDef.OccurrencesoCompOcc.Definition.Document.ActiveRenderStyle = oCompOcc.Definition.Document.RenderStyles("HVGM")Next
View 3 Replies
View Related
Oct 19, 2012
I have a code which I want to rotate a part. I have a text parameter 6 and 7. If one of the values is active I want to give the component a certain rotation.
Under the 'Hoekkoppeling' parameter is the angle constraint.
Below the
If Parameter ("KlemHoekstuk-01: 1", "KoppelingType") = 7
Then Hoekkoppeling = 60 deg
ElseIf Parameter ("KlemHoekstuk-01: 1", "KoppelingType") = 6
Then Angle = -60 deg
End If
I now get always an error on the second and fourth line.
I feel that the specify for the value is incorrectly.
View 4 Replies
View Related
Jul 19, 2013
I have using Inventor api to open an assembly file.But while open the .iam file it will show all the suppressed elements.how can we hide this suppressed elements from showing?
here is my code
Dim asdoc As AssemblyDocumentasdoc = inventorApp.Documents.Open("F:ArunMasterMaster_RF-VH-ZZ-0800-0500-0600.iam")
View 4 Replies
View Related
Jan 6, 2014
I have made a sheet metal panel with three hole in it.Every hole has separate parameters.
When i suppress one hole and i go to the BOM i don't want to see the values of the parameters from the suppressed hole.
Is there a way to when i suppress one or two holes the values don't show in the BOM?
Everytime i suppress one or two holes the values show up in the BOM.
View 1 Replies
View Related
Feb 28, 2012
I have created some "programs" to automate drawing creation of some of our most common products. The problem I hav eis with my assembly drawing. When parts are suppressed and unsuppressed, they don't seem to behave the same way that features do. When you dimension a part feature in an idw and suppress that feature, if a week later you unsuppress that feature the dimenensions come back. Parts don't seem to follow this behaviour. If you dimension a part, suppress it, open and save the drawing, then later unsuppress it and open the drawing back up the dimesnions do not come back. Is there anyway for me to get these dimensions to "stick"?
View 9 Replies
View Related
Sep 19, 2012
I'm working on a main assembly. I want to edit the i properties of components within a sub-assembly, this is fine for "RING:1"
iProperties.Value("RING:1","Project", "Description")="A79-H020B001"
but I get an error message when i try to edit the iproperties of a patterned component within the sub-assembly.
View 3 Replies
View Related
Dec 2, 2013
I created a simple Part with some parameters to drive dimensions. Saved the part. I created an Assembly. Saved the assembly. Clicked Place iLogic Component. The Place iLogic Component window appeared Selected the Part. I can see the preview window (Part-01) & the parameter window... Used default values. Hit OK NO PART INSERTED! Using Inventor Pro 2014 64-BitLudesroc
View 1 Replies
View Related
Nov 22, 2011
I have a wall of frames, if you will, and some frames within this wall are different sizes. When doing the BOM, I want to be able to combine anything that has the same stock number as well as the same cut length. The only way I have thought to do this so far is to cycle through each stock number and if the cut length is the same, I override the quantity of one and change the BOM Structure of the other to "Reference".
How can I change the BOM Structure to reference without selecting the part or going through the BOM Editor? Is there some VBA code I could utilize? I am striking out by solely using iLogic.
View 2 Replies
View Related
Feb 9, 2012
Is there code for changing the color (or other properties) of the visible edges of a component in a drawing view, the same way I can do it manually by right-clicking a component and choosing Properties?
I wrote this rule to change the color of each individual drawing curve:
Edit: Ignore the "<!". It's the only way I could get the iLogic code to successfully post in the message
Spoiler (Highlight to read)<!Dim drawViews AsDrawingView
For Each drawViews In ThisApplication.ActiveDocument.ActiveSheet.DrawingViews
occ3 = drawViews.ReferencedDocumentDescriptor.ReferencedDocument.ComponentDefinition.Occurrences.ItemByName("GF_Plenum:1")
Dim newColor3 As Color
newColor3 = ThisApplication.TransientObjects.CreateColor(0,255,255)
[code]....
View 2 Replies
View Related
Feb 22, 2012
Show on Place Component
If I set this to true, then when I "place iLogic component", I don't get the form displayed or the parameter table or the model preview.
If set True, displays the form when placing this model as a component in an assembly. This setting affects Place Component and Place iLogic Component. If the template file has a form, this setting also affects Create In-Place Component.
View 1 Replies
View Related
Oct 1, 2013
The commented code does not work. I want to be able to open a part and change its size parameters before i open the assembly. this code will run as an external rule in a new empty file.
If i can do it without opening the part, that is even better. Test can I open a part, change a param, then close part.
Dim fname As String
fname ="C:Workspacemy_progchanF_BB_L.ipt"
Dim pDoc as PartDocument = ThisApplication.Documents.Open(fname,False)
pDoc = ThisApplication.Documents.Open(fname)
These are just attempts to find a syntax that works. I need the method to change the parameter.
'param = pDoc.PartComponentDefinition.Parameter.Param("TKNS")
'pdoc.parameter.Param("TKNS") = 8
pdoc.Save
pdoc.Close
View 4 Replies
View Related
Sep 28, 2012
I have a simple code below trying to iterate through all the assembly component and copy the iProperties > Occurrece Name (i.e. "Part1:1") and paste it to iProperties > Project tab > Part Number field for each individual part in assembly.
' set a reference to the assembly component definintion.
' This assumes an assembly document is open.
Dim oAsmCompDef As AssemblyComponentDefinition
oAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition
'Iterate through all of the occurrences
Dim oOccurrence As ComponentOccurrence
For Each oOccurrence In oAsmCompDef.Occurrences
Dim oName As String
oName = oOccurrence.Name
iProperties.Value(oOccurrence.Name, "Project", "Part Number") = oName
MessageBox.Show(oOccurrence.Name, "iLogic")
Next
The Debug message shows the correct output for every iteration, but when I check each part's properties they all have the Occurrence Name of the last part in the aseembly.
View 4 Replies
View Related
Jan 22, 2013
I wish to create a form that with multiple buttons. Each button will place another component (platform, stairs, ladder, railing).
I wish to place them using 'Place iLogic Component"
I know you can call this command by:
ThisApplication.CommandManager.ControlDefinitions.Item("iLogic.PlaceComponent").Execute
But is it possible to automatically browse to and open a file this way using a path "C:CPSVaultPlatformComponentsStairs.iam" within this command?
View 6 Replies
View Related
Jan 5, 2014
So I have been going round and round in circles on this one iam trying to use replace component within ilogic which is fine with switching one part for another but I want a drop down of parts so it replaces which ever one is active the problem I am having is establishing which one is active. So below is what I have so far but the problem is you cant seem to reference a part that is not in the assembly so I keep getting the error
The component named "Flange 1" was not found for example. I just need a way of establishing which one is currently in the assembly but with out referencing components that are not there.
If Component.IsActive("Flange 1")=True Then current = 1
If Component.IsActive("Flange 2")=True Then current = 2
If Component.IsActive("Flange 3")=True Then current = 3
If part = 1 And current = 2 Then Component.Replace("flange 2", "Flange 1.ipt", True) End If
If part = 1 And current = 3 Then Component.Replace("flange 3", "Flange 1.ipt", True) End If
If part = 2 And current = 1 Then Component.Replace("flange 1", "Flange 2.ipt", True) End If
If part = 2 And current = 3 Then Component.Replace("flange 3", "Flange 2.ipt", True) End If
If part = 3 And current = 1 Then Component.Replace("flange 1", "Flange 3.ipt", True) End If
If part = 3 And current = 2 Then Component.Replace("flange 2", "Flange 3.ipt", True) End If
View 4 Replies
View Related
Apr 1, 2013
I found this code to create a custom iProperty in the current, open document:
Dim propertyName As String = "MyProperty"Dim propertyValue as String = "Test Value"customPropertySet = ThisDoc.Document.PropertySets.Item("Inventor User Defined Properties")Try prop = customPropertySet.Item(propertyName)Catch ' Assume error means not found customPropertySet.Add("", propertyName)End TryiProperties.Value("Custom", propertyName) = propertyValue
I have a iLogic rule that goes through each component of an assembly, counts how many times it occurs in the assembly, and then assigns that value to an iProparty (i.e. it inserts the total quantity of the part in some iProperty). Currently, however, it assigns the value to a default iProperty value, "Authority". I'd like, instead, for it to assign it to a custom iProperty called "Total QTY". However, I don't know how to tell Inventor to do the above code for a component in the assembly rather than the assembly itself. Below is my entire code. I've labeled where I'm guessing the above code should go. How I'd modify the above code to create the iProperty in the component being processed by the rule at that point?
Current
''True comment: Begin '''Commented-out Begin '''PartDocumentObject = 12290''AssemblyDocumentObject = 12291Dim openDoc As DocumentopenDoc = ThisDoc.DocumentDim docFile As DocumentIf openDoc.DocumentType = 12291 Then''If the open document is an assembly:''For each document referenced in this document:For
[code]......
View 2 Replies
View Related
Sep 30, 2013
How could I center the suppressed constraint? I woul like to selecet it in the listbox.
Private Sub CommandButton1_Click()
Dim oAssDoc As AssemblyDocument
Set oAssDoc = ThisApplication.ActiveDocument
Dim oConstraint As AssemblyConstraint
For Each oConstraint In oAssDoc.ComponentDefinition.Constraints
If oConstraint.HealthStatus = kSuppressedHealth Then
Call ListBox1.AddItem(oConstraint.Name)
End If
Next oConstraint
End Sub
View 7 Replies
View Related
Jun 28, 2013
I am trying to model a large Control panel assembly using Inventor Pro 2011. It comprises of a main assembly with several adaptive sub assemblies containing the various items. (Relays assy, label assy, fixing assy etc). All works ok until I start using Levels of Detail to enable me break the assembly into smaller workable parts. I.e. Left door, right door, main panel full, main panel no doors etc. These will be used to create view reps from for my drawing views at a later date.
The problem I am having is I keep getting constraints failing on parts which are suppressed in various levels of detail. An example of this Is when I go to right door LOD and do a rebuild all, I get constraint errors from item relating to the main panel which is suppressed. I can suppress the constraint causing the error but when I return to the full panel LOD the constraint is still suppressed and the parts appear In the wrong place.
View 1 Replies
View Related