Failed to create the part's controls in Eclipse with Salesforce

梦想与她 提交于 2019-11-30 08:53:25

I had the same error. I fixed it by switching the eclipse workspace. Go to menu File->Switch Workspace->Other, and then select the same workspace you were working with. Eclipse will restart and you should not get the error.

I faced the same issue my default editor for JSP was Web page editor. Which I changed to JSP editor and everything is fine.

PS: To change to JSP editor Right click on JSP page -->open with jsp .

I got the "failed to create the part's controls" error one day when I opened Eclipse and tried to view a java file I had been working on. When I opened the file I needed, it showed a red X and NullPointerException instead of the code. The error log mentioned "event loop exception" for some reason.
I restarted Eclipse, and the error was still there. I cleaned the project, updated the project, deleted and re-imported the project, deleted and re-imported the file, and the error still was there. As a last resort, I restarted Eclipse again and then the file was fine. So one of the clean/update/delete/import steps worked but I don't know which one.

This problem occur because of in eclipse default editor is not able to identify extension of that file. If you right click on file and open it with respective text editor ,problem will be solved

user2740011

Use eclipse -clean from command prompt to solve this problem.

Stan

I solved my problem like this:

in my case problem was that the server was resin and I didn't have the resin server extension installed

In ecllipse, every file types has some associated default formats and one of the default format set to the particular file type.

You can see this in General -> Editors -> File Associations-

This issue generally occurs when we open any file in the format which is not the default format of the particular types.

I got same issue when I opened one of the Java file in text format in ecllipse and then I started getting the same issue. After research, I observed that AspectJ/Java Editor was setting as default. After reset it to Java Editor, the problem got resolved.

Steps : 1. General -> Editors -> File Associations- 2. Select the content type and choose the default format for it. 3. Restart the ecllipse.

In general, it is some default file format that set in ecllipse causing the same issue.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!