Community
Showing results for 
Search instead for 
Do you mean 
Reply

Shortcut keys.

New Member
Posts: 2
Country: United_Kingdom

Shortcut keys.

Here's my code for creating menu items in ACT!

 

String aURN = “act-ui://com.act/application/menu/tools/MyMenu”;
String aMenuText = “My New Menu Item”;
Image aImage = Resource1.MyIcon;
CommandBarControl.ItemDisplayStyle aStyle = CommandBarControl.ItemDisplayStype.ImageAndText;
Keys[] aKeys = { Keys.Control | Keys.M };

AddMenuItem(aURN, aMenuText, new CommandHandler(MyMenuHandler), aStyle, aImage, aKeys);

 

This seems to work great except for the shortcut keys. In versions 10 and 11 this works fine and the menuitem displays 

 

'My New Menu Item     Ctrl+M'.

 

But it doesnt work in 12-15. I've tried changing the keys to see if it had something to to with M being used elsewhere but it doesnt seem to make a difference. 

 

Can anyone help?

Employee
Posts: 1,163
Country: USA

Re: Shortcut keys.

I did get this to work, but not with Ctrl+M, that key combination is already used to schedule a new meeting, it would add the shortcut text to the menu, but wouldn't work. If I changed it to a key combination that wasn't bound to anything already (in my case Ctrl+E) then it worked fine. I know you said you'd tried other keys, but check to see if the alternatives you tried are also already bound.

Matthew Wood
Act! SDK Support
Community Moderator