Inventor Customization

Distinguished Contributor
Posts: 234
Registered: ‎05-09-2005
Message 1 of 2 (622 Views)

Change iProperty Material Using VBA

622 Views, 1 Replies
03-02-2013 01:13 AM

Can anybody help?


I am trying to change the iProperties "Physical" "Material" using an Inventor VBA macro


Can anybody tell me how this can be achieved?


For example, say the material is set to "DEFAULT" and I want to change it to "TITANUIM", how can I do this using VBA?


Many thanks in advance!!!!



Posts: 411
Registered: ‎01-06-2009
Message 2 of 2 (595 Views)

Re: Change iProperty Material Using VBA

03-03-2013 11:43 PM in reply to: isocam

If you want to change the material of the document you should use the PartDocument.ComponentDefinition.Material to change it.


If you change the property of material, it won't really change the document material, but you can do it with below code:


PartDocument.PropertySets(3).Item("Material").Value = "Titanium"


Rocky Zhang
Inventor API
Manufacturing Solutions
Autodesk, Inc.

You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.

Need installation help?

Start with some of our most frequented solutions to get help installing your software.

Ask the Community

Inventor Exchange Apps

Created by the community for the community, Autodesk Exchange Apps for Autodesk Inventor helps you achieve greater speed, accuracy, and automation from concept to manufacturing.

Connect with Inventor