Community
Inventor Programming - iLogic, Macros, AddIns & Apprentice
Inventor iLogic, Macros, AddIns & Apprentice Forum. Share your knowledge, ask questions, and explore popular Inventor topics related to programming, creating add-ins, macros, working with the API or creating iLogic tools.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Get Active Visual Style and store in a Variable

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
J.VandeMerckt
147 Views, 2 Replies

Get Active Visual Style and store in a Variable

Hi Everyone.

I'm trying to retrieve the active visual style and store it in a variable for later use in my code.
Right now I can only change the visual style to chosen style.

Dim oView As Inventor.View = ThisApplication.ActiveView
oView.DisplayMode = DisplayModeEnum.kRealisticRendering

The idea is to change the visual style, then render and then revert the visual style back to the original one.
All help is welcome!

Tags (1)
2 REPLIES 2
Message 2 of 3

Hi @J.VandeMerckt . The View.DisplayMode function has a Gets/Sets property, so your code can get the active view. Here is an example:

Dim oView As Inventor.View = ThisApplication.ActiveView
Dim oActView As DisplayModeEnum = oView.DisplayMode
MessageBox.Show(oActView.ToString(), "Active Visual Style:")

Andrii Humeniuk - Leading design engineer

LinkedIn | My free Inventor Addin | My Repositories

Did you find this reply helpful ? If so please use the Accept as Solution/Like.

EESignature

Message 3 of 3

This seems to be true.
Thanks!

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Technology Administrators


Autodesk Design & Make Report