Message 1 of 2

Not applicable
11-17-2016
07:21 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Im new in Inventor API. i have been done to create drawing view from ipt file and add 3 projected view also set automatic centerline for cylindrical and hole feature.
for my project i need to get 2d coordinate (x,y) from all center cylindrical and hole feature in drawing (oview1 component).
Any idea to extract centerline coordinate from oview1 variable?
This only important snippet of my code :
Dim oDrawingDoc As DrawingDocument oDrawingDoc = ThisApplication.ActiveDocument Dim oSheet As Sheet oSheet = oDrawingDoc.Sheets.Item(1) Dim oPoint1 As Point2d oPoint1 = ThisApplication.TransientGeometry.CreatePoint2d(5.0#, 5.0#) Dim oPartDoc As PartDocument oPartDoc = ThisApplication.Documents.Open("D:\SyncCloud\OneDrive\AutoDesk Saved Files\Base1\Frame\ISO 00000017.ipt", False) Dim oView1 As DrawingView oView1 = oSheet.DrawingViews.AddBaseView(oPartDoc, oPoint1, 1.0#, ViewOrientationTypeEnum.kTopViewOrientation, DrawingViewStyleEnum.kHiddenLineDrawingViewStyle) Dim oACS As AutomatedCenterlineSettings oView1.GetAutomatedCenterlineSettings(oACS) oACS.ApplyToCylinders = True oACS.ApplyToHoles = True oView1.SetAutomatedCenterlineSettings(oACS)
Solved! Go to Solution.