-1

I have a certain View.

In this view there is a TreeViewer.

When I right-click one element of the tree, I open the contextual menu that trigger the command "rename".

In the HANDLER of this command, how can I obtain the ID of the view of the selected element?

Is it possible to get it?

Thanks very much to everyone will answer!

Guardian
  • 107
  • 1
  • 6

1 Answers1

1

See HandlerUtil. In this example, since you right-click on an element in a view, it should become active and you can use

HandlerUtil.getActivePartId(e);
Alexey Romanov
  • 167,066
  • 35
  • 309
  • 487