Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Adding a new command action
Adding a new command action [message #771380] Tue, 27 December 2011 04:23 Go to next message
John Lussmyer is currently offline John LussmyerFriend
Messages: 96
Registered: December 2010
Member
I'm trying to add a new Action to my app.
I've created the Action class.
In the ApplicationActionBarAdvisor, I create an instance of it, and call register() for that instance.
I also add it to the coolbar and the menu.
In my Manifest, I've created a new command under "org.eclipse.ui.commands" and specified the id, name, description, and categoryId.

When I run the app, the command works, BUT during app startup I get this exception:

java.lang.Exception
at org.eclipse.jface.action.ExternalActionManager$CommandCallback.isActive(ExternalActionManager.java:370)
at org.eclipse.jface.action.ActionContributionItem.isCommandActive(ActionContributionItem.java:647)

The comments in that code say the command is not yet defined.
So, where do I need to define it?
Re: Adding a new command action [message #771695 is a reply to message #771380] Tue, 27 December 2011 23:48 Go to previous message
John Lussmyer is currently offline John LussmyerFriend
Messages: 96
Registered: December 2010
Member
Finally figured it out! I had a one-letter case difference between the command ID definition, and the manifest definition.
Previous Topic:[solved] Java exit code 13 on RCP Application start
Next Topic:Finding what is under the cursor in context popup
Goto Forum:
  


Current Time: Fri Nov 28 15:11:24 GMT 2014

Powered by FUDForum. Page generated in 0.02609 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software