12-20-2016
04:30 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
12-20-2016
04:30 AM
This is straight from my addin and it works for me. This allows you to take an existing material and set it for the file.
' Get the asset that corresponds with the selected material
Dim oAsset As Asset
oAsset = EM_AddIn.StandardAddInServer.m_inventorApplication.AssetLibraries.Item("EllimetalMaterialLibrary") _
.MaterialAssets.Item("Material name here")
' Set the document material
oDoc.ActiveMaterial = oAsset
Your code seems odd to me to always add a material to use it. Just use a existing one.
Please kudo if this post was helpfull
Please accept as solution if your problem was solved
Inventor 2014 SP2