Keep ribbon tab selected.

Keep ribbon tab selected.

Anonymous
Not applicable
630 Views
3 Replies
Message 1 of 4

Keep ribbon tab selected.

Anonymous
Not applicable

Hi,

I have a macro that builds our standard parts list. The icon for this I have placed on the Annotate Tab, but every time I run the macro it changes back to the Place Views tab. Any ideas how I can keep it on the currently selected tab?

I'm not the best at programming and the macro was written for us, but I'm ok at trouble shooting and making small changes to programs. So it would be best to KISS. Me being the stupid one.

Thanks,

Ozitag

0 Likes
631 Views
3 Replies
Replies (3)
Message 2 of 4

martin_mmj
Enthusiast
Enthusiast

Maybe this VBA code will help you.

Martin

 

Sub ChangePanelToToolsTab()
   ' Get the ribbon associated with the part document
   Dim oPartRibbon As Ribbon
   Set oPartRibbon = ThisApplication.UserInterfaceManager.Ribbons.Item("Part")

   ' Get your own tab
   Dim oTab As RibbonTab
   Set oTab = oPartRibbon.RibbonTabs.Item("your_own_tab_name")
   'activate it
   oTab.Active = True
End Sub
0 Likes
Message 3 of 4

skyngu
Collaborator
Collaborator

can i keep ribbon tab selected when I start "drawing " enviroment in inventor 2010?

Autodesk Inventor Professional 2019
0 Likes
Message 4 of 4

Anonymous
Not applicable

Couldn't get this to work, although I haven't spent too much time on it as the work has pile up on my desk.  Will look at it a bit more in the following weeks.

Thanks for the suggestion anyway.

Ozitag.

0 Likes