Error in opening .m files
显示 更早的评论
whenever I try to open any .m file I get this error... Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError: com/mathworks/cmlink/api/customization/CustomizationWidgetFactory at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Unknown Source) at com.mathworks.matlab.api.explorer.ExtensionRegistry.addExtension(ExtensionRegistry.java:51) at com.mathworks.mlwidgets.explorer.model.ExplorerExtensionRegistry.init(ExplorerExtensionRegistry.java:106) at com.mathworks.mlwidgets.explorer.model.ExplorerExtensionRegistry.<clinit>(ExplorerExtensionRegistry.java:44) at com.mathworks.mlwidgets.explorer.model.actions.DefaultActionInput.<init>(DefaultActionInput.java:34) at com.mathworks.mde.editor.PathActionInputSource.createInput(PathActionInputSource.java:41) at com.mathworks.mde.editor.PathActionInputSource.getCurrentInput(PathActionInputSource.java:37) at com.mathworks.mlwidgets.explorer.model.actions.ActionManager.instantiateActions(ActionManager.java:307) at com.mathworks.mlwidgets.explorer.model.actions.ActionManager.<init>(ActionManager.java:113) at com.mathworks.mde.editor.EditorViewClient.createPathActionManager(EditorViewClient.java:702) at com.mathworks.mde.editor.EditorViewClient.init(EditorViewClient.java:246) at com.mathworks.mde.editor.EditorViewClient.<init>(EditorViewClient.java:177) at com.mathworks.mde.editor.MatlabEditorApplication.createEditorViewClient(MatlabEditorApplication.java:865) at com.mathworks.mde.editor.MatlabEditorApplication.createEditorViewClient(MatlabEditorApplication.java:850) at com.mathworks.mde.editor.MatlabEditorApplication.createEditorViewClientFromExistingFile(MatlabEditorApplication.java:842) at com.mathworks.mde.editor.MatlabEditorApplication.access$500(MatlabEditorApplication.java:82) at com.mathworks.mde.editor.MatlabEditorApplication$7.runWithOutput(MatlabEditorApplication.java:567) at com.mathworks.jmi.AWTUtilities$Invoker$2.watchedRun(AWTUtilities.java:475) at com.mathworks.jmi.AWTUtilities$WatchedRunnable.run(AWTUtilities.java:436) at java.awt.event.InvocationEvent.dispatch(Unknown Source) at java.awt.EventQueue.dispatchEventImpl(Unknown Source) at java.awt.EventQueue.access$200(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue.dispatchEvent(Unknown Source) at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.run(Unknown Source) Caused by: java.lang.ClassNotFoundException: com.mathworks.cmlink.api.customization.CustomizationWidgetFactory at java.net.URLClassLoader$1.run(Unknown Source) at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) ... 34 more
Please help me solve the problem
2 个评论
Jan
2018-4-16
Give us a chance to help you. Explain, when the problem occurred: After installing Matlab? After a specific change, e.g. an update of the OS? Maybe a Java update under MacOS? Did you try to repair the Matlab installation? Perhaps un-install and re-install? From where do you try to "open" the M-file?
S HEMANTH
2018-4-16
回答(1 个)
Jan
2018-4-16
0 个投票
Restore the Matlab folder from your backup. If you do not have a backup - bad idea. Try to install Matlab again without a further un-installation. This might repair Matlab such, that an uninstall works.
If this does not work also, contact the technical support. Of course, check your hard disk at first by chkdsk and sfc /scannow - but such standard methods do not concern Matlab, but the operating system only.
类别
在 帮助中心 和 File Exchange 中查找有关 Startup and Shutdown 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!