adding grounded to keyboard shortcut

adding grounded to keyboard shortcut

Anonymous
Not applicable
2,392 Views
6 Replies
Message 1 of 7

adding grounded to keyboard shortcut

Anonymous
Not applicable

I struggle to find grounded in tools->customize->keyboard->categories->unknown menu

 

If anyone knows of a trick or where to find it that would be of great help to my work tempo.

0 Likes
Accepted solutions (4)
2,393 Views
6 Replies
Replies (6)
Message 2 of 7

WCrihfield
Mentor
Mentor
Accepted solution

There isn't a predefined tool in the listing for that specific function.

You would have to either create a button that runs the VBA macro code, or perhaps modify the Properties of the existing built-in Button Definition to set up a shortcut through by code.

By default, it has no shortcut.

The command name for that ControlDefinition is "AssemblyGroundCtxCmd".

You can execute it with the following line of iLogic code:

ThisApplication.CommandManager.ControlDefinitions.Item("AssemblyGroundCtxCmd").Execute

Wesley Crihfield

EESignature

(Not an Autodesk Employee)

Message 3 of 7

Anonymous
Not applicable
Accepted solution

Well that is just terrible. all menus should have option to be hotkeyed. Inventor is better than Solidworks on this. But not by much. Thanks for the help. Perhaps i one day, can figure out how use that code++ to shape Inventor properly.

 

Edit: opsy.

0 Likes
Message 4 of 7

WCrihfield
Mentor
Mentor
Accepted solution

Yep.  Sometimes you can modify the 'DefaultShortcut' for a ControlDefinition through a fairly simple code, but not for ones that are 'Built-in", like this one is.

The code would look something like this:

Dim oCD As ControlDefinition = ThisApplication.CommandManager.ControlDefinitions.Item("AssemblyGroundCtxCmd")

oCD.DefaultShortcut = 'String type data here

 

Wesley Crihfield

EESignature

(Not an Autodesk Employee)

Message 5 of 7

rayessle
Advocate
Advocate

Not quite the same but if you right click on the part (either in the tree or on screen) then press the "g" key on your keyboard it will ground it, or un-ground it if already grounded. Same as "v" switches visibility. When you see the menu after you right click you will see letters that are underlined in the commands. These are the keys you can press as a shortcut instead of clicking. You would still have to click on the part before pressing a hotkey so the number of clicks is the same just a right click instead of a left click.

 

Regards

Ray

0 Likes
Message 6 of 7

k14348
Advocate
Advocate
Accepted solution

Hi,

   Go to customize and add key for ground and root component. ss attached for ref.

 

-Karth

Message 7 of 7

WCrihfield
Mentor
Mentor

That one is:

ThisApplication.CommandManager.ControlDefinitions.Item("AssemblyBonusTools_GroundAndRootComponentCmd")

If you have the Assembly Bonus Tools installed, this command will Ground and constrain & align its origin to the origin of the assembly...not just ground it.

 

Wesley Crihfield

EESignature

(Not an Autodesk Employee)

0 Likes