I'd like to set up a keyboard shortcut so that when I press the 'V' key, inventor toggles the visibility of the selected part or assembly. However, "Visibility" seems to be about the only command that doesn't exist in the list of keyboard shortcuts*. I found this post in which someone says it's not possible, but might be using VBA. I've done some iLogic but know nothing about Inventor's inner-working VBA. I'm wondering if there's some workaround, VBA or otherwise, that'll allow me to toggle visibility using the 'V' key. Any suggestions would be appreciated. Thanks!
*actually it does but it says it's only available for use in Inventor Studio. Go figure.
Using: Autodesk Inventor 2013 Product Design Suite
Solved! Go to Solution.
Solved by adam.nagy. Go to Solution.
Hi,
You could create a VBA command like this:
Sub ToggleVisibility() Dim ss As SelectSet Set ss = ThisApplication.ActiveDocument.SelectSet Dim obj As Object For Each obj In ss If TypeOf obj Is ComponentOccurrence Then Dim occ As ComponentOccurrence Set occ = obj occ.Visible = Not occ.Visible End If Next End Sub
And then assign the V key to it in the "Customize" dialog (right-click anywhere on the Ribbon and select "Customize User Commands")
As you can see in my case there are two commands already using that shortcut, so when I press 'V', I will have to select which command should run:
I hope this helps.
Cheers,
this is super, I also thanks so much adam.nagy. I work in version 2014, and I think that is not even in version 2016.