I have some problems using a context menu in a treeViewer. I follow the readings of Vogella, added two commands, the respective handlers, and a MPopupMenu with the respective Handled MenuItems to the part containing the treeViewer in the Application.d4xmi.

In the coded part I injected the EMenuService and added the code as explained by Vogella:

Three questions:
a) Is your MPopupMenu in the model after startup?
b) As child of the part where your viewer is located?
c) With the correct id ("popupmenu")?

You can check by using the Live-Model-Editor to check it during runtime.

1) You need to add some bundles to your product:
- org.eclipse.e4.tools.emf.liveeditor
- org.eclipse.e4.tools.emf.ui
- org.eclipse.e4.tools.emf.ui.script.js
and the required plug-ins
2) After you start the product like this, press Alt-Shift-F9