04-27-2020
10:24 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
04-27-2020
10:24 AM
Here is the code.
Dim oPartDoc As AssemblyDocument oPartDoc = ThisApplication.Documents.Open("C:\Users\jishee\Documents\Work\Inventor_modeling\Dimensioning_Test\U001_Assembly.iam", False) Dim oDrawingDoc As DrawingDocument oDrawingDoc = ThisApplication.ActiveDocument Dim oSheet As Sheet oSheet = oDrawingDoc.Sheets.Item(1) Dim oPoint1 As Point2d oPoint1 = ThisApplication.TransientGeometry.CreatePoint2d(4.5#, 6#) Dim oView1 As DrawingView oView1 = oSheet.DrawingViews.AddBaseView(oPartDoc, oPoint1, 0.03125#, kFrontViewOrientation, kHiddenLineRemovedDrawingViewStyle) ActiveSheet.View(oView1.Name).SetCenter(4.5, 6) Call oPartDoc.Close(True)