11-02-2018
07:15 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
11-02-2018
07:15 AM
Yes, you do need to change the code to account for every kind of feature you'll come across in the model tree before you can rename it. Typically you have to get down through the component definition, then the collection of features you want to look at, then the specific feature out of that collection, then you can get to the property that stores the name you see in the browser.
Are you only looking to rename specific features in the model tree? Otherwise it'll take a while if you want to account for everything Inventor has to offer.
Right now that code is only looking at Surface Bodies, you'll have to do a loop for every kind of feature you want to rename.