AutoCAD Inventor :: BOM Renumbering And Part List Sort By Item (iLogic)
May 15, 2013
i = MessageBox.Show("Do you wish to Renumber & Sort BOM?", "My iLogic Dialog", MessageBoxButtons.YesNo, MessageBoxIcon.Warning, MessageBoxDefaultButton.Button1) If i = vbyes ThenTrace.WriteLine ("INV - Transfer; User Selection; Do you wish to Renumber & Sort BOM? - YES")'Renumbers & Sort BOMoPartsList1.Renumber oPartsList1.SaveItemOverridesToBOMoPartsList1.Sort("ITEM") Trace.WriteLine ("INV-ExternalRule - Renumber & Sort BOM#")Else if i = vbno Trace.WriteLine ("INV - Transfer; User Selection; Do you wish to change Renumber & Sort BOM? - NO")End if
what i want to do, is renumber the BOM by (001) then go to part list and sort by item.
View 9 Replies
ADVERTISEMENT
Nov 7, 2011
I have got some ilogic code that i have patched together to sort my parts list in inventor which works great but it will not update all sheets at the same time as when we design we have multiple sheets with parts list on and the odd one without.
add to this code to update all sheets partlists and also recognise that some sheets will not have partslists on so this will need to skip.
below is code that is used to sort
Format:HTML Format Version:1.0 StartHTML: 165 EndHTML: 4558 StartFragment: 314 EndFragment: 4526 StartSelection: 314 EndSelection: 314
SyntaxEditor Code Snippet
Format:HTML Format Version:1.0 StartHTML: 165 EndHTML: 4558 StartFragment: 314 EndFragment: 4526 StartSelection: 314 EndSelection: 314
[Code] ...........
View 4 Replies
View Related
Jan 30, 2013
I have created an iAssembly which contains 4 assembly variations. I now want to create an assembly drawing for these variations.
In this case all my assembly variations will have the same assembly part number as essentially they are all the same assembly except for a few "change over parts".
I intend to have one drawing with multiple sheets. Each sheet will have one variation of the assembly on it with a BOM for that specific variation. The problem I am having though is that the drawing BOM for each variation are linked and as a result each drawing has an inconsistant item numbering (for someone in the workshop who doesnt understand the CAD package and iAssemblies - They ask the question: Why are you skipping item numbers in the BOM's)
Is there any way I can get each BOM to show the item numbers sequentially? I tried editing the drawing BOM item number but the problem is that method propogates the item number changes to all the other BOM's as well.... (It is also tedious AND in my opinion it is generally bad practice to edit the BOM at the drawing level)
View 1 Replies
View Related
Jun 11, 2013
I found the following code on Curtis Waguespack site. [URL] ........
View 3 Replies
View Related
May 22, 2012
I have been unable to find any code to sort the BOM, there are lots of snippets to sort and modify the Parts list.
How to sort the Assembly BOM?
Sort parameters:
PARTS Only
"BOM Structure"
then by
Custom Parameter "TYPE"
Then By
Part Number
Then "Renumber" starting at 1
Autodesk Product Design Suite Premium 2014 SP1 Build 222
Intel Core i7 (950@3.07GHz)
Windows 7x64 (Home) - 12GB Ram
Nvidia GeForce GTX 560 Ti (1Gig - Ver:331.65)
View 1 Replies
View Related
Feb 20, 2013
I have an iLogic rule that populates the fields shown below in our title block. The DIM. Values are strings set with H,W,L values. This works well, but I have an additional need to sort these values in ascending order, so the smallest value is first followed by the next largest and finally the largest value. (4.000x5.000x14.000). I haven't had much luck finding any information about how this can be done. I did however come across some code here that someone else was using for a similar feature.
Dim sizes As New List (Of Decimal)sizes.Add(bH)sizes.Add(bW)sizes.Add(bL)sizes.Sort()D1 = sizes(1)D2 = sizes(2)D3 = sizes(3)
This is what I have been attempting, though it does not work. I get the following error "Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index". I'm not sure if my list type is correct (Decimal), but no matter what I choose it fails. The (bH,bW,bL) are the actual block dimensions pulled from the .ipt file. Once sorted I want the values of each position (1),(2),(3) to be assigned to (D1),(D2),(D3) so I can place them in my title block in the correct order.
View 3 Replies
View Related
Jun 13, 2011
I want to use iLogic to:
1.Sort an assembly BOM by Part Number.
2. Renumber Items in the BOM as sorted.
3. Sort a drawing Parts list by item number.
The background to my problem is that i have an assembly which is working beautifully turning components on and off (suppressing/activating in LOD reps) as defined by iLogic rules (iLogic is awesome). The problem is whenever a part is turned on/activated again, it shows up at the bottom of the BOM and Parts list out of order (would be nice if parts went back in the list where they came from).
View 7 Replies
View Related
Feb 19, 2013
For some reason the item numbers in my parts list are blank. All the other information populates.
I've gone to the assmebly and varified that the BOM tabs are active and there are numbers in there.
If I inser the parts list as 'legacy' it works fine.
I can't use the renumber function, it just makes all theh item number boxes go yellow in the parts list box,
Inventor 2013.
View 9 Replies
View Related
Jul 9, 2012
When I created a parts list this morning the list started with item 2 and skipped item 8 as shown below.
why would it do that? I know I can renumber the list, but then when I expand the subassembly to show the subassembly parts, they stay numbered 10.1, 10.2 ect. even though the subassembly has become item 8 with the renumbering. If I expand the subassembly before renumbering, I loose the indented numbering format and simply get numbers 1 to 18. True I could manually renumber all the components, but what would be the reason the parts don't come into the parts list numbered sequentially to start with?
View 4 Replies
View Related
Sep 13, 2012
Is there an application or document setting that will make the default state of a row in a linked excel file used in a parts list default to "off" (not visble)?
More specifically, make this apply to added rows.
We have finish schedules in excel that everyone links a parts list to whenerver they need to display a finish schedule on the idw. However, when we add rows (new finishes) to the the excel finish schedule, they get displayed on the idw parts list next time the idw updates wether they are needed or not. Our practice is to only show finishes that are used on the drawing - so frequently a large portion of the whole finish schedule needs to be set to "off" or invisible.
View 3 Replies
View Related
Jan 30, 2013
I have a subassembly that has been patterned.
I need to toggle the visibility of a part in that subassembly in each pattern element.
How do I refer to the part?
I have declared an object for my pattern, and can toggle the suppression on any element.
But I need to get at an individual component inside the element.
I've been trying something like this:
oPattern.OccurrencePatternElements.Item(X).Component.Visible("Valance Jig Frame - 1in:1") = False
View 1 Replies
View Related
Jan 3, 2014
IV2012 API with VB:
How can i add an item to a Multi-Value-List of an existing User Parameter in Inventor2012 (Accessing API with Visual Basic) ?
My idea is for example:
uParams.Item(i).ExpressionList.AddItem(As String)
The problem is, that such a function "AddItem" doesn't exist.
View 4 Replies
View Related
Sep 17, 2012
Is there any method to sort sketch blocks in a part file? All of our sketch blocks are numbered with a profile number. When we create a new multi-body assembly we will often derive 50-100 of them into the master file. It would be great if we could sort them by profile number.
The next best solution would be the ability to create sub-folders to place them in by type (sort of like assembly folders), but I'm pretty sure this isn't possible.
View 1 Replies
View Related
Apr 1, 2013
I`m looking for the iLogic code that can change one parameter (user defined) for each (ipt) part in assembly (iam)
The one below doesn`t work.
Sub Main Dim oApp As Inventor.Application = ThisApplication Dim oAssy As Inventor.AssemblyDocument = oApp.ActiveDocument For Each oSubDoc as Inventor.Document In oAssy.AllReferencedDocuments On Error Resume Next Parameter(oSubDoc, "FH") = 15.26 Next End Sub
View 5 Replies
View Related
Apr 30, 2012
I just wondered if can I assign a particular ITEM number to a particular part, instead of relying on order in the assembly.
I unsterstand I can overrite it in BOM but can I have it controlled from the part, so any time I instert it into an assembly, this particular number in ITEM coulmn pops up?
View 9 Replies
View Related
Feb 8, 2013
Is there a way to connect parameters from part1 to part 2 using iLogic, without using an assembly.
View 9 Replies
View Related
Apr 25, 2012
I don't know how useful this will be but I was trying to figure out how to track what item number in an assembly any given part may be. I was thinking that on an individual part drawing I may want to reference the item number that is used in an assembly's Bill of Material for that part. I can't find where this may be stored for retrieval. If I do this I would want it to be automated so that if the BoM were renumbered the part file and drawing would update to the new item number.
This may not be possible since any part may be used in any number of different assemblies with different locations in a Bill of Material. Most of our assemblies use "one off" parts that are only used in that assembly so it may be possible in my particular situation to do this if there is a way to get at the BoM item number and connect it to the IPT file.
View 4 Replies
View Related
Sep 24, 2012
I have created a new item in content center in my personnel library. When i am creating a new item in content center its creating *.ipt file somewhere ? If so from which location i can open the part file ?
View 3 Replies
View Related
Jun 15, 2012
I am trying to modify the code Brian Ekins posted on Mod the Machine to renumber balloons across sheets. [uRL ....
It works great unless the item on the additional sheet is a sub-assembly. I believe it is because PartDef is declared as a PartComponentDefinition and there is nothing in the code to handle an assembly.
Dim partDef As PartComponentDefinition
Set partDef = drawBOMRow.BOMRow.ComponentDefinitions.Item(1)
partInfo(I - 1).ReferencedFile = partDef.Document.FullFileName
The Set partDef line was giving me a runtime error when it came to an assembly in the BOM until I added
"On Error Resume Next" at the start of the loop.
I tried changing the declaration to ComponentDefinition. It compiled fine, but didn't do anything. I think I'll have to add some duplicate code to handle an assembly in the BOM. Is there a better way to do this? Am I even on the right track?
View 3 Replies
View Related
Nov 18, 2013
Trying to have ilogic find parts in an assembly that start with 900C7 so I can link the to a cell in excel showing the QTY and the LENGTH..
Right now I am just trying to get ilogic to find and list them then I know I can move to the next step..
Example:
900C71.250
900C72.125
900C7A.750
900C7P1.1875
And many more.
Here is what I have but it keeps posting the NOTHING message box. I have a few of the parts in the assembly and a few none 900C7 parts.
Dim openDoc As Inventor.DocumentDim docFile As Inventor.DocumentDim assemblyDoc As AssemblyDocumentDim partOcc As ComponentOccurrenceDim FNamePos As LongDim docFName As StringDim oList As Collection = New CollectionopenDoc = ThisApplication.ActiveDocumentIf openDoc.DocumentType
[Code] .....
Here is a screen shot of the excel file what I am trying.
View 9 Replies
View Related
Dec 11, 2012
Is there a way I can write some code, so that in idw, I can choose from two different text for "Description" in BOM table? My work place requires to show material information when it's a fabrication drawing, to show part description in assembly drawing in "Description" column.
At the moment, we just override material information (for example, 40x40x3 RHS) to part description (RHS Spreader). It's not very safe to do that. Most of the times, we just forget to change it.
Autodesk Inventor 2013 SP1.1 64-Bit
Vista Business 64-Bit
E8400, 8GB, ATI FireGL V5600
View 5 Replies
View Related
Dec 11, 2012
I have a section of code (see below) which runs a program which highlights a part/subassembly red, then gives the user a list dialgue box in order to easily replace the compent. At present, I have this code repeated for each part/subassembly in my main assemby (i.e. FRAME, POWER_RISER, BUSBAR_CHAMBER, BUSBAR_ASSEMBLY...).
Having the code repeated multiple times, means it is very time consuming to modify. I want to be able to generate a list then have the code below, run for each of the entries in the list. So I need something along the lines of
dim mylist as something
mylist = FRAME, POWER_RISER, BUSBAR_CHAMBER, BUSBAR_ASSEMBLY...
FOR each entry in mylist
run all the code below (with the words 'BUSBAR_ASSEMBLY' replaced with 'mylist'
END
[Code] ........
Autodesk Inventor Professional 2011
Windows 7 Enterprise, 64-bit
View 3 Replies
View Related
Nov 15, 2013
It takes a list of Parameters and cycles through the assembly looking for parts with the same parameter names. It then copies the value of the parameter from the assembly down to the part.
It occured to be that this would be more efficient if I didn't have to manually create a list of parameters to compare.
What I'd like to do is create a list of all parameters in the assembly file that begin with the prefix 'A_', and compare this list against the parameter list held in each subassmbly and part file in the assembly, copying the values down as before.how to build the parameter list?
' set a reference to the assembly component definintion.' This assumes an assembly document is open.Dim oAsmCompDef As Assembly Component DefinitionoAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition'Iterate through all of the occurrencesDim oOccurrence As ComponentOccurrenceFor Each oOccurrence In oAsmCompDef.Occurrences'check for and skip virtual components'(in case a virtual component
[code]....
View 9 Replies
View Related
Dec 10, 2012
I have almost got my ilogic part working the way I want it. I have to go into the parameters and choose from a Multi-Value list.
Is there a way in ilogic to get a input box to come up when I place my part in an assembly (like an ipart)?
View 3 Replies
View Related
Nov 4, 2011
I use a setup with Shader List (Volume) with two mists. One regular and one to blur out the horizon. After working on the scene for some time I notice that the shader list now contains eight copies of the last shader. I think I would remember if I did that. So, whats up with the shader list?
View 1 Replies
View Related
Jul 18, 2012
I populate the members of a (text) Paramter from an Excel file
i.e.
MyArrayList = GoExcel.CellValues.("MyExcelWB.xlsx", Sheet1", "A2","")
Now this list contains plenty of duplicates. Is there anyway inside iLogic to remove the duplicates.
View 1 Replies
View Related
Oct 26, 2011
Is there a way in iLogic to set the input list box width?
View 7 Replies
View Related
Oct 4, 2012
I curently have a rule that generates a part list automatically in a drawing. the problem is that I want the rule to be continuisly running but it keeps generating 2,3,5... parts lists. I need an if statment to check if a parts list already exists.
iLogicVb.UpdateWhenDone = True On Error Resume Next ' Set a reference to the drawing document. ' This assumes a drawing document is active. Dim oDrawDoc As DrawingDocument oDrawDoc = ThisApplication.ActiveDocument 'Set a reference to the
[Code].....
View 2 Replies
View Related
Jun 19, 2013
im trying to programatically add a parts list into a drawing whilst programatically creating the drawing - the code works fine without the parts list code. The error its showing is 'Parameter incorect' on the line that sais PartsList.add(... In the past when ive got this error with other code it has been because ive used an incorrect parameter (e.g. decimal instead of an integer).
My error is somewhere inside the oPartsList.add(>>ERROR SOMEWHERE HERE<<<)
oDrawDoc = InvApp.Documents.Add(Inventor.DocumentTypeEnum.kDrawingDocumentObject,AssyTemplate,True)
oSheet = oDrawDoc.Sheets.Item(1)
[Code].....
View 1 Replies
View Related
Nov 18, 2010
I need to generate an iLogic rule exporting Parts List (not BOM) from a IDW to a specific folder in XLS format.
Using Autodesk AutoCAD Inventor 2011
View 9 Replies
View Related
Jul 8, 2012
I am trying to populate a multi-value user parameter with a list composed of the various materials available from the iProperties "Physical" tab. So far I have this:
For Each material In iProperties.Materials
Bracket_Material.Items.Add(material)
Next
iProperties.Material=Bracket_Material
Running the Rule gets this error message:
Rule Compile Errors in Material_Rule, in _Mounting_bracket.ipt
Error on Line 2 : 'Bracket_Material' is not declared. It may be inaccessible due to its protection level.
I think I am doing the "Bracket_Material.Items.Add(material) " line wrong, but I don't know enough VB to fix it. It seems to me it IS declared in the Parameters table - isn't adding the parameter to the parameter table sufficient to declare it?
Eventually I want to add the Bracket_Material Parameter to a form so the user can select material from drop down list and assign it to part.
View 3 Replies
View Related