Message 1 of 10
PartsLists.Add error with Inventor 2017?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
with ilogic I used to be able to use something like this in previous versions of Inventor:
Dim oDrawDoc As DrawingDocument Dim oSheet As Sheet Dim oDrawingView As DrawingView Dim oPlacementPoint As Point2d Dim oPartsList As PartsList oDrawDoc = ThisApplication.ActiveDocument oSheet = oDrawDoc.ActiveSheet oDrawingView = oSheet.DrawingViews(1) oPlacementPoint = ThisApplication.TransientGeometry.CreatePoint2d(60, 20) oPartsList = oSheet.PartsLists.Add(oDrawingView, oPlacementPoint)
But now in Inventor 2017 I'm needing to specify the PartsList Level, otherwise I get an error.
Meaning that I must use something like this:
Dim oDrawDoc As DrawingDocument Dim oSheet As Sheet Dim oDrawingView As DrawingView Dim oPlacementPoint As Point2d Dim oPartsList As PartsList oDrawDoc = ThisApplication.ActiveDocument oSheet = oDrawDoc.ActiveSheet oDrawingView = oSheet.DrawingViews(1) oPlacementPoint = ThisApplication.TransientGeometry.CreatePoint2d(60, 20) oPartsList = oSheet.PartsLists.Add(oDrawingView, oPlacementPoint,PartsListLevelEnum.kFirstLevelComponents)
I'm trying to determine if there was a change, or if there is something else going on.
Can anyone else confirm that the first version creates an error and the 2nd version works in Inventor 2017... or any other version?
Thanks!
Curtis