' save as DWG Imports Inventor.ViewOrientationTypeEnum Imports Inventor.DrawingViewStyleEnum Dim oDrawingDoc as DrawingDocument Dim oPartDoc as Document Dim oSheet As sheet Dim oTG As TransientGeometry Dim oView1 as DrawingView Dim oView2 as DrawingView Dim oView3 as DrawingView Dim oView4 as DrawingView Dim oView5 as DrawingView ViewScale = 1/20 'Ask to create drawing? dwgQuery=MsgBox("Would you like to Create a drawing for this MODEL?", vbYesNo,"Drawing Selection") If dwgQuery = vbYes Then oPartDoc = ThisDoc.Document 'Define IDW Template File Location oDrawingDoc = ThisApplication.Documents.Add(kDrawingDocumentObject, "C:\Work12\TEMPLATES\PPPI-PART BORDER NL.idw", True) ' oDrawingDoc = ThisApplication.Documents.Add(kDrawingDocumentObject, "", True) oSheet = oDrawingDoc.Sheets.Item(1) 'Define 2d view bottom left corner points for four views oPoint1 = ThisApplication.TransientGeometry.CreatePoint2d(9, 10) ' front view oPoint2 = ThisApplication.TransientGeometry.CreatePoint2d(9, 14) ' top view oPoint3 = ThisApplication.TransientGeometry.CreatePoint2d(18, 10)' right view oPoint4 = ThisApplication.TransientGeometry.CreatePoint2d(20, 14)' iso view oPoint5 = ThisApplication.TransientGeometry.CreatePoint2d(7, 10)' flat pattern oBaseView = oSheet.DrawingViews.AddBaseView(oPartDoc,oPoint1, ViewScale,kFrontViewOrientation, kHiddenLineDrawingViewStyle, "Default") oView2 = oSheet.DrawingViews.AddProjectedView(oBaseView,oPoint2, kHiddenLineDrawingViewStyle, ViewScale) oView3 = oSheet.DrawingViews.AddProjectedView(oBaseView,oPoint3, kHiddenLineDrawingViewStyle, ViewScale) oView4 = oSheet.DrawingViews.AddProjectedView(oBaseView,oPoint4, kHiddenLineDrawingViewStyle, 1/25) 'oView5 = ????? End If