Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Antoher "unable to open editor, unknown ID" problem
Antoher "unable to open editor, unknown ID" problem [message #441892] Sat, 07 January 2006 20:38 Go to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

Hi...

sorry for posting an old problem again, but I coulnd't find any working solution for my problem in the threads... so please give me some advice if you have..

I'm trying to develop a GUI based on RCP. Right know I'd like to create an editor, which pops up, when an item of the tree viewer is selected by choosing a menu entry.
But I can't get the editor working, cause I got the PartInitException: Unable to open editor, unknown editor ID.
The steps I've made so far are as follows:
- creating the editor class, which is subclass of EditorPart (TestEditor)
- creating the editor input class, which implements IEditorInput (TestEditorInput)
- specify the action class(TestAction), to supply the menu entry on the GUI, which also calls the function

page.openEditor(input,TestEditor.ID)

This ID is defined in the editor class as follows:
public static String ID = "test.editor.testEditor"

and also defined in the plugin.xml for an editor extension.

Below I paste the failure report I got, when I tried to choose the menu

Can someone please help me? I'm quite desperate..:-(

Thank you very much in advance

Regards
Paul

org.eclipse.ui.PartInitException: Unable to open editor, unknown editor ID: test.testEditor
at org.eclipse.ui.internal.EditorManager.openEditor(EditorManag er.java:630)
at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditorBatched( WorkbenchPage.java:2381)
at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(Workben chPage.java:2316)
at org.eclipse.ui.internal.WorkbenchPage.access$10(WorkbenchPag e.java:2308)
at org.eclipse.ui.internal.WorkbenchPage$9.run(WorkbenchPage.ja va:2294)
at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator .java:69)
at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPa ge.java:2289)
at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPa ge.java:2274)
at test.action.TestAction.run(TestAction.java:93)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:492 )
at org.eclipse.jface.action.ActionContributionItem.handleWidget Selection(ActionContributionItem.java:530)
at org.eclipse.jface.action.ActionContributionItem.access$2(Act ionContributionItem.java:480)
at org.eclipse.jface.action.ActionContributionItem$5.handleEven t(ActionContributionItem.java:392)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:914)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3285)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2905)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:1762)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1726)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:397)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:143)
at test.core.TestApplication.run(TestApplication.java:19)
at org.eclipse.core.internal.runtime.PlatformActivator$1.run(Pl atformActivator.java:109)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:92)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:68)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:379)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:177)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.eclipse.core.launcher.Main.invokeFramework(Main.java:338 )
at org.eclipse.core.launcher.Main.basicRun(Main.java:282)
at org.eclipse.core.launcher.Main.run(Main.java:977)
at org.eclipse.core.launcher.Main.main(Main.java:952)


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979789.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441893 is a reply to message #441892] Sat, 07 January 2006 20:48 Go to previous messageGo to next message
James Leotta is currently offline James LeottaFriend
Messages: 202
Registered: July 2009
Senior Member
Paul, did you create the testEditorActionBarContributor which implements
IActionBarContributor - because you need to.

Paul Sentosa wrote:
> Hi...
>
> sorry for posting an old problem again, but I coulnd't find any working solution for my problem in the threads... so please give me some advice if you have..
>
> I'm trying to develop a GUI based on RCP. Right know I'd like to create an editor, which pops up, when an item of the tree viewer is selected by choosing a menu entry.
> But I can't get the editor working, cause I got the PartInitException: Unable to open editor, unknown editor ID.
> The steps I've made so far are as follows:
> - creating the editor class, which is subclass of EditorPart (TestEditor)
> - creating the editor input class, which implements IEditorInput (TestEditorInput)
> - specify the action class(TestAction), to supply the menu entry on the GUI, which also calls the function
>
> page.openEditor(input,TestEditor.ID)
>
> This ID is defined in the editor class as follows:
> public static String ID = "test.editor.testEditor"
>
> and also defined in the plugin.xml for an editor extension.
>
> Below I paste the failure report I got, when I tried to choose the menu
>
> Can someone please help me? I'm quite desperate..:-(
>
> Thank you very much in advance
>
> Regards
> Paul
>
> org.eclipse.ui.PartInitException: Unable to open editor, unknown editor ID: test.testEditor
> at org.eclipse.ui.internal.EditorManager.openEditor(EditorManag er.java:630)
> at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditorBatched( WorkbenchPage.java:2381)
> at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(Workben chPage.java:2316)
> at org.eclipse.ui.internal.WorkbenchPage.access$10(WorkbenchPag e.java:2308)
> at org.eclipse.ui.internal.WorkbenchPage$9.run(WorkbenchPage.ja va:2294)
> at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator .java:69)
> at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPa ge.java:2289)
> at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPa ge.java:2274)
> at test.action.TestAction.run(TestAction.java:93)
> at org.eclipse.jface.action.Action.runWithEvent(Action.java:492 )
> at org.eclipse.jface.action.ActionContributionItem.handleWidget Selection(ActionContributionItem.java:530)
> at org.eclipse.jface.action.ActionContributionItem.access$2(Act ionContributionItem.java:480)
> at org.eclipse.jface.action.ActionContributionItem$5.handleEven t(ActionContributionItem.java:392)
> at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :66)
> at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:914)
> at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3285)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2905)
> at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:1762)
> at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1726)
> at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:397)
> at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:143)
> at test.core.TestApplication.run(TestApplication.java:19)
> at org.eclipse.core.internal.runtime.PlatformActivator$1.run(Pl atformActivator.java:109)
> at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:92)
> at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:68)
> at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:379)
> at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:177)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at org.eclipse.core.launcher.Main.invokeFramework(Main.java:338 )
> at org.eclipse.core.launcher.Main.basicRun(Main.java:282)
> at org.eclipse.core.launcher.Main.run(Main.java:977)
> at org.eclipse.core.launcher.Main.main(Main.java:952)
>
>
> --
> View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979789.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441896 is a reply to message #441893] Sat, 07 January 2006 21:32 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

Hi James...thanks for the reply..

I didn't create any ActionBarContributor bcs I don't what it is for...
I read a book about RCP, showing examples how to create an editor. This examples shows only these 3 classes I mentioned before.
Moreover, I've just tried to follow your suggestion, but I got directly following message for implementing IActionBarContributor:
Discouraged access: The type IActionBarContributor is not accessible due to restriction on required
library C:\eclipse\plugins\org.eclipse.ui.workbench_3.2.0.I20051214- 1200.jar

Sorry for bothering you...but could you please explain more, what I can do with it?
Thanks before..

Best Regards
ps


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979872.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441897 is a reply to message #441892] Sun, 08 January 2006 01:31 Go to previous messageGo to next message
Haris Peco is currently offline Haris PecoFriend
Messages: 1072
Registered: July 2009
Senior Member
you define ID 'test.editor.testEditor', and try open ID test.testEditor
(i think)
Paul Sentosa wrote:

> Hi...
>
> sorry for posting an old problem again, but I coulnd't find any working
> solution for my problem in the threads... so please give me some advice if
> you have..
>
> I'm trying to develop a GUI based on RCP. Right know I'd like to create an
> editor, which pops up, when an item of the tree viewer is selected by
> choosing a menu entry. But I can't get the editor working, cause I got the
> PartInitException: Unable to open editor, unknown editor ID. The steps
> I've made so far are as follows: - creating the editor class, which is
> subclass of EditorPart (TestEditor) - creating the editor input class,
> which implements IEditorInput (TestEditorInput) - specify the action
> class(TestAction), to supply the menu entry on the GUI, which also calls
> the function
>
> page.openEditor(input,TestEditor.ID)
>
> This ID is defined in the editor class as follows:
> public static String ID = "test.editor.testEditor"
>
> and also defined in the plugin.xml for an editor extension.
>
> Below I paste the failure report I got, when I tried to choose the menu
>
> Can someone please help me? I'm quite desperate..:-(
>
> Thank you very much in advance
>
> Regards
> Paul
>
> org.eclipse.ui.PartInitException: Unable to open editor, unknown editor
> ID: test.testEditor at
> org.eclipse.ui.internal.EditorManager.openEditor(EditorManag er.java:630)
> at
>
org.eclipse.ui.internal.WorkbenchPage.busyOpenEditorBatched( WorkbenchPage.java:2381)
> at
>
org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(Workben chPage.java:2316)
> at
> org.eclipse.ui.internal.WorkbenchPage.access$10(WorkbenchPag e.java:2308)
> at org.eclipse.ui.internal.WorkbenchPage$9.run(WorkbenchPage.ja va:2294) at
> org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator .java:69) at
> org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPa ge.java:2289)
> at
> org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPa ge.java:2274)
> at test.action.TestAction.run(TestAction.java:93) at
> org.eclipse.jface.action.Action.runWithEvent(Action.java:492 ) at
>
org.eclipse.jface.action.ActionContributionItem.handleWidget Selection(ActionContributionItem.java:530)
> at
> org.eclipse.jface.action.ActionContributionItem.access$
(ActionContributionItem.java:480)
> at
>
org.eclipse.jface.action.ActionContributionItem$5.handleEven t(ActionContributionItem.java:392)
> at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :66) at
> org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:914) at
> org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3285) at
> org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2905) at
> org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:1762) at
> org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1726) at
>
org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:397)
> at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:143) at
> test.core.TestApplication.run(TestApplication.java:19) at
>
org.eclipse.core.internal.runtime.PlatformActivator$1.run(Pl atformActivator.java:109)
> at
>
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:92)
> at
>
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:68)
> at
>
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:379)
> at
>
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:177)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
>
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
> at
>
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585) at
> org.eclipse.core.launcher.Main.invokeFramework(Main.java:338 ) at
> org.eclipse.core.launcher.Main.basicRun(Main.java:282) at
> org.eclipse.core.launcher.Main.run(Main.java:977) at
> org.eclipse.core.launcher.Main.main(Main.java:952)
>
>
> --
> View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979789.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441899 is a reply to message #441897] Sun, 08 January 2006 00:42 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

Hi Haris, thanks...

I don't quite understand your explanation... do you mean that I've mistyped the ID? It can't be the case, because I just type page.openPage(input, TestEditor.ID)..that is: I refer directly to the static attribute of the editor...
sorry if I misunderstood...but could you please explain a bit more?
Thanks in advance..

Regards
ps


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979880.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441900 is a reply to message #441896] Sun, 08 January 2006 01:00 Go to previous messageGo to next message
James Leotta is currently offline James LeottaFriend
Messages: 202
Registered: July 2009
Senior Member
Never heard of this one. Sounds like some sort of security access
restriction. The IActionBarContributor doesn't require anything to be
done to it just that it be created. Also the tooltip text in the
IEditor part needs to have something returned other then null. I am
still learing RCP but I have all my editors opening when I complete all
I have stated.

There is a good example HYPERBOLA which the authors have written a book
about which is good to get a starting idea of what is happening. Its in
the RCP examples on the Eclipse site.

Paul Sentosa wrote:
> Hi James...thanks for the reply..
>
> I didn't create any ActionBarContributor bcs I don't what it is for...
> I read a book about RCP, showing examples how to create an editor. This examples shows only these 3 classes I mentioned before.
> Moreover, I've just tried to follow your suggestion, but I got directly following message for implementing IActionBarContributor:
> Discouraged access: The type IActionBarContributor is not accessible due to restriction on required
> library C:\eclipse\plugins\org.eclipse.ui.workbench_3.2.0.I20051214- 1200.jar
>
> Sorry for bothering you...but could you please explain more, what I can do with it?
> Thanks before..
>
> Best Regards
> ps
>
>
> --
> View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979872.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441901 is a reply to message #441899] Sun, 08 January 2006 03:14 Go to previous messageGo to next message
Haris Peco is currently offline Haris PecoFriend
Messages: 1072
Registered: July 2009
Senior Member
see you first message in this thread
you have this in code :

public static String ID = "test.editor.testEditor"

and this is from error message
org.eclipse.ui.PartInitException: Unable to open editor, unknown editor ID:
test.testEditor
Paul Sentosa wrote:

> Hi Haris, thanks...
>
> I don't quite understand your explanation... do you mean that I've
> mistyped the ID? It can't be the case, because I just type
> page.openPage(input, TestEditor.ID)..that is: I refer directly to the
> static attribute of the editor... sorry if I misunderstood...but could you
> please explain a bit more? Thanks in advance..
>
> Regards
> ps
>
>
> --
> View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979880.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441908 is a reply to message #441901] Sun, 08 January 2006 09:27 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

Oh yes...sorry...but unfortunately that was just mis-paste..actually the error report just shows the ID I've given as parameter in the function openEditor...

Maybe any other ideas?Thanks before...

Regards
ps


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979919.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441909 is a reply to message #441900] Sun, 08 January 2006 09:48 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

Hi...

the example of HYPERBOLA is exactly the example from the book I meant before...and I followed the steps as stated in it, but I couldn't get it working..unfortunately the book didn't mention anything about such case..

From the error report I got, I tried to follow up the first line, which is:

<b>PartInitException</b>:Unable to open editor, unknown editor ID: net.sf.bibxmleditor.ui.modifyEditor
at org.eclipse.ui.internal.EditorManager.openEditor(EditorManag er.java:630)
....

From the class EditorManager line 630 are following codes to see:

IEditorRegistry reg = getEditorRegistry();
EditorDescriptor desc = (EditorDescriptor) <b>reg.findEditor(editorId);</b>
<b>if (desc == null)</b> {
throw new PartInitException(
NLS.bind(WorkbenchMessages.EditorManager_unknownEditorIDMess age,editorId ));
}

I suppose that the EditorRegistry couldn' find the editor. Do you have any idea, what this could mean, and how I can solve this problem?
Thanks in advance

ps


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979921.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441915 is a reply to message #441909] Sun, 08 January 2006 14:49 Go to previous messageGo to next message
Haris Peco is currently offline Haris PecoFriend
Messages: 1072
Registered: July 2009
Senior Member
Paul,
your error
org.eclipse.ui.PartInitException: Unable to open editor, unknown editor ID:
test.testEditor
tell that you try open unknown editor ID - you have defined another ID
or your definition (editors extension point) is invalid
check double your extension point
Paul Sentosa wrote:

> Hi...
>
> the example of HYPERBOLA is exactly the example from the book I meant
> before...and I followed the steps as stated in it, but I couldn't get it
> working..unfortunately the book didn't mention anything about such case..
>
> From the error report I got, I tried to follow up the first line, which
> is:
>
> <b>PartInitException</b>:Unable to open editor, unknown editor ID:
> net.sf.bibxmleditor.ui.modifyEditor at
> org.eclipse.ui.internal.EditorManager.openEditor(EditorManag er.java:630)
> ...
>
> From the class EditorManager line 630 are following codes to see:
>
> IEditorRegistry reg = getEditorRegistry();
> EditorDescriptor desc = (EditorDescriptor)
> <b>reg.findEditor(editorId);</b> <b>if (desc == null)</b> {
> throw new PartInitException(
>
NLS.bind(WorkbenchMessages.EditorManager_unknownEditorIDMess age,editorId
> ));
> }
>
> I suppose that the EditorRegistry couldn' find the editor. Do you have any
> idea, what this could mean, and how I can solve this problem? Thanks in
> advance
>
> ps
>
>
> --
> View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979921.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441922 is a reply to message #441915] Sun, 08 January 2006 21:41 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

I've checked the ID once more: in the editor class and in the plugin.xml file for the editor extension point. They are exactly the same.
I've even tried to rewrite all the classes and still I got the same report.
Does it make any sense, if I reinstall eclipse?

Regards
ps


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979990.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441925 is a reply to message #441922] Sun, 08 January 2006 23:18 Go to previous messageGo to next message
Haris Peco is currently offline Haris PecoFriend
Messages: 1072
Registered: July 2009
Senior Member
send your extension point - maybe it isn't ID problem
your extension definition is complete wrong (probably)
Paul Sentosa wrote:

> I've checked the ID once more: in the editor class and in the plugin.xml
> file for the editor extension point. They are exactly the same. I've even
> tried to rewrite all the classes and still I got the same report. Does it
> make any sense, if I reinstall eclipse?
>
> Regards
> ps
>
>
> --
> View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979990.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441926 is a reply to message #441925] Sun, 08 January 2006 22:46 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

The only part that has something to do with the editor is this one:
<extension
point="org.eclipse.ui.editors">
<editor
class="test.editor.TestEditor"
default="false"
id="test.editor.testEditor"
name="Test Editor"/>
</extension>
Is there something wrong?


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91979998.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441928 is a reply to message #441926] Mon, 09 January 2006 00:44 Go to previous messageGo to next message
Haris Peco is currently offline Haris PecoFriend
Messages: 1072
Registered: July 2009
Senior Member
Paul Sentosa wrote:

> The only part that has something to do with the editor is this one:
> <extension
> point="org.eclipse.ui.editors">
> <editor
> class="test.editor.TestEditor"
> default="false"
> id="test.editor.testEditor"
> name="Test Editor"/>
> </extension>
> Is there something wrong?
>
>
it is fine, but invalid ID tell that eclipse can't find this ID
maybe , plugin with editor extension isn't included or
extension is commented in plugin.xml and eclipse can't find this extension
Re: Antoher "unable to open editor, unknown ID" problem [message #441929 is a reply to message #441928] Mon, 09 January 2006 00:11 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

The plugin with editor extension is for sure included, bcs I still have some other extension in there, and they are all recognized. It isn't commented as well.
Do you know something about the Editor Registry? Because the part of codes that causes this problem is this one:
IEditorRegistry reg = getEditorRegistry();
EditorDescriptor desc = (EditorDescriptor) reg.findEditor(editorId);
if (desc == null) {
throw new PartInitException(
NLS.bind(WorkbenchMessages.EditorManager_unknownEditorIDMess age,editorId ));
}


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91980004.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441941 is a reply to message #441929] Mon, 09 January 2006 10:07 Go to previous messageGo to next message
Haris Peco is currently offline Haris PecoFriend
Messages: 1072
Registered: July 2009
Senior Member
Paul,
it is clear from your error - eclipse doesn't recognize your ID
it can be that you mistake type id, noninculde plugin, mistake in extension
try debug your code for more information
i know that editors extension work fine, because i use it
Paul Sentosa wrote:

> The plugin with editor extension is for sure included, bcs I still have
> some other extension in there, and they are all recognized. It isn't
> commented as well. Do you know something about the Editor Registry?
> Because the part of codes that causes this problem is this one:
> IEditorRegistry reg = getEditorRegistry(); EditorDescriptor desc =
> (EditorDescriptor) reg.findEditor(editorId); if (desc == null) { throw new
> PartInitException(
> NLS.bind(WorkbenchMessages.EditorManager_unknownEditorIDMess age,editorId
> )); }
>
>
> --
> View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91980004.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441942 is a reply to message #441892] Mon, 09 January 2006 09:16 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: alexander.nikiforov.freesurf.ch

Have you specified the 'icon' attribute in the plugin extension editor for your editor? It may sound strange, but the icon attribute is required if you supply your own class in the 'class' attribute to implement the IEditorPart interface.

Well, the icon itself does not need to exist, but the 'icon' attribute's field must not be empty. Without the icon defined, your editor never gets into the editor registry when the plugin extensions are read, so an attempt later to retrieve this editor by its id fails, even though the editor ID is correct.


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91980066.html
Re: Antoher "unable to open editor, unknown ID" problem [message #441966 is a reply to message #441942] Mon, 09 January 2006 15:55 Go to previous messageGo to next message
Haris Peco is currently offline Haris PecoFriend
Messages: 1072
Registered: July 2009
Senior Member
Alexander,
i think that you are correct
Alexander Nikiforov wrote:

> Have you specified the 'icon' attribute in the plugin extension editor for
> your editor? It may sound strange, but the icon attribute is required if
> you supply your own class in the 'class' attribute to implement the
> IEditorPart interface.
>
> Well, the icon itself does not need to exist, but the 'icon' attribute's
> field must not be empty. Without the icon defined, your editor never gets
> into the editor registry when the plugin extensions are read, so an
> attempt later to retrieve this editor by its id fails, even though the
> editor ID is correct.
>
>
Re: Antoher "unable to open editor, unknown ID" problem [message #442001 is a reply to message #441966] Mon, 09 January 2006 18:40 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

hi Alexander, Haris, James...

many thanks for your help!!..it is really the "icon" that causes the problem.
Once again...many thanks!

ps:sorry for the late reply..just coming back..

ps


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91980232.html
Re: Antoher "unable to open editor, unknown ID" problem [message #442012 is a reply to message #442001] Mon, 09 January 2006 22:53 Go to previous messageGo to next message
Ben Brown is currently offline Ben BrownFriend
Messages: 23
Registered: July 2009
Junior Member
I always find that its safer to use the "Extensions" tab on the
plugin.xml when, rather than entering directly into the plugin.xml, when
you're adding in extensions. Quite a few of the eclipse extensions
have templates that will help you to set things up,
org.eclipse.ui.editors being one of them.

Hope you have fun using Eclipse, I know it makes my life easier... most
of the time :)

Paul Sentosa wrote:
> hi Alexander, Haris, James...
>
> many thanks for your help!!..it is really the "icon" that causes the problem.
> Once again...many thanks!
>
> ps:sorry for the late reply..just coming back..
>
> ps
>
>
> --
> View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91980232.html
Re: Antoher "unable to open editor, unknown ID" problem [message #442013 is a reply to message #442012] Mon, 09 January 2006 23:42 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: psentosa.yahoo.com

Thanks for the tip!
I just tried to create an editor using a template..and it does put an icon for the editor automatically...

Have fun too!:-)

ps


--
View in EZ forum: http://www.eclipsezone.com/eclipse/forums/m91980287.html
Re: Antoher "unable to open editor, unknown ID" problem [message #443093 is a reply to message #441892] Mon, 23 January 2006 15:34 Go to previous messageGo to next message
Dumitrascu Vasile is currently offline Dumitrascu VasileFriend
Messages: 3
Registered: July 2009
Junior Member
Hello

Had the same exception - the mistake was to forget to set a icon for the editor in the extension point declared in plugin.xml. Hope that helps somebody....
Re: Antoher "unable to open editor, unknown ID" problem [message #443094 is a reply to message #441892] Mon, 23 January 2006 15:41 Go to previous messageGo to next message
Dumitrascu Vasile is currently offline Dumitrascu VasileFriend
Messages: 3
Registered: July 2009
Junior Member
ooops.. it seems you've got it in the end :)
Re: Antoher &quot;unable to open editor, unknown ID&quot; problem [message #465169 is a reply to message #441942] Sat, 24 March 2007 12:54 Go to previous message
Eclipse UserFriend
Originally posted by: tapamayghosh.gmail.com

Thanks a lot....

I also had the problem regarding opening the editor and I found it was not working just because of the absence of icon selection. So your suggesion has solved my problem but I may ask you for further help. Thank you Very much once again.
Previous Topic:Drag Drop Link
Next Topic:RCP project - Multiple developers
Goto Forum:
  


Current Time: Wed Jan 15 11:56:54 GMT 2025

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

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

Back to the top