Message 1 of 9
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi all and thanks in advance for any help given.
The problem that I am looking to solve is I'm sure quite simple. When creating a new assembly from a template file named "Hopper Fabrication.iam" I want to trigger the creation and placement of a new part from a template called "Master Hopper.ipt" and put it inside the new assembly.
So far I have the following
Dim oTemplate As String = "C:\Users\Public\Documents\Templates\Master Hopper.ipt" Dim oDoc As AssemblyDocument = ThisApplication.ActiveDocument Dim oDocumentDefinition As AssemblyComponentDefinition = oDoc.ComponentDefinition Dim oTG As TransientGeometry = ThisApplication.TransientGeometry Dim oMatrix As Matrix = oTG.CreateMatrix oDocumentDefinition.Occurrences.Add(oTemplate,oMatrix)
This is placing the actual template in rather than creating a new part based on the template rather than creating a new in-place compoent based on the named template
Can anyone help me out please.
Mike
Autodesk Certified Professional
Solved! Go to Solution.