Message 1 of 5
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
This is a code used to make a view from the assy. In a code I have to write the location of the assy.
Since the drawing and the assembly are in the same folder I would like to find a way not to write the exact location of the assy. I tried a few things but it did not work.
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#, 5#) Dim oAssyDoc As AssemblyDocument oAssyDoc = ThisApplication.Documents.Open(C:\...\"My_assy.iam", False) Dim oView1 As DrawingView oView1 = oSheet.DrawingViews.AddBaseView(oAssyDoc, _ oPoint1, 1#, kBottomViewOrientation, kHiddenLineDrawingViewStyle) Call oAssyDoc.Close(True)
If somebody could help it would be great 🙂
Tom
Solved! Go to Solution.