Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse 4 » MPart in Handler assigned to the part is not injected? (SOLVED)
MPart in Handler assigned to the part is not injected? (SOLVED) [message #1783942] Tue, 20 March 2018 15:21
Christian Eugster is currently offline Christian EugsterFriend
Messages: 175
Registered: July 2009
Location: St. Gallen Switzerland
Senior Member
Hi
I have an e4 app with perspective and Parts in PartStack. I add a Handler to a part and inject this part in the handler class. Running the app I get an exception:
org.eclipse.e4.core.di.InjectionException: Unable to process "ResetHandler.part": no actual value was found for the argument "MPart".
I am not yet very close to injection, so i appreciate any hint, Thank you!
If I inject the part in the execute method like this:
@Execute
public void execute(MPart part)
{
}
it does work.
Christian

Solution: It seems that MPart is only available if the handler is assigned directly within an MPart in the application.e4xmi

[Updated on: Tue, 20 March 2018 20:55]

Report message to a moderator

Previous Topic:E4 model service find method doesn't find MPopupMenu
Next Topic:Enabling/disabling dynamically Tool Item
Goto Forum:
  


Current Time: Sun Nov 18 04:49:37 GMT 2018

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

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

Back to the top