I am not able to build. I know the error is in jdkAnnotations.jar. I reinstalled android studio, but the problem persists. It also says no IDEA annotations attached in jdk 1.8. Should i reinstall jdk 1.8 also? i am clicking on the button that says attach annotations but nothing is happening. Please help. And why is this problem happening? is there something wrong in any xml resource file or what?
C:/Program Files/Android/Android Studio/lib/jdkAnnotations.jar!/java/awt/event/annotations.xml: Content is not allowed in prolog.
org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 1; Content is not allowed in prolog.
at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLScanner.reportFatalError(Unknown Source)
at org.apache.xerces.impl.XMLDocumentScannerImpl$PrologDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
I got the same error today. Just reinstalling Android Studio did not help. The following steps worked for me:
Close Android Studio
Go to C:\Users\Username
Delete the whole folders: ".AndroidStudioX.X" and ".gradle"
Start Android Studio
Now all the Settings will be reinstalled and you can work on with your project
Had the same problem, it seems like others stated, a BOM problem, some HEX bytes at the begin of the file to mark its file format. To solve it:
Open C:/Program Files/Android/Android Studio/lib/jdkAnnotations.jar with winRar or other tool capable of editing .jar files.
Find annotations.xml in /java/awt/event/ iside the .jar and open it with a text viewer.
Copy its content to a new file with the same name (annotations.xml) anywhere in your computer.
Delete the original annotations.xml file inside the .jar file, and add your copy to the same location.
Then in your Android project project try to click in the Attach annotations option, and that should solve the problem.
Good luck!
Related
My program runs fine when I run it on eclipse but when I package it in a jar file, I get this error when I run it.
java.lang.IllegalStateException: Location is not set.
at javafx.fxml.FXMLLoader.loadImpl(Unknown Source)
at javafx.fxml.FXMLLoader.load(Unknown Source)
at controller.MainController.initAnalyzer(MainController.java:144)
at applicationMain.Main.start(Main.java:32)
at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$162(Unknown Source)
at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$175(Unknown Source)
at com.sun.javafx.application.PlatformImpl.lambda$null$173(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.javafx.application.PlatformImpl.lambda$runLater$174(Unknown Source)
at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(Unknown Source)
at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at com.sun.glass.ui.win.WinApplication.lambda$null$148(Unknown Source)
at java.lang.Thread.run(Unknown Source)
I am certain that the path is correct. I have tried to change the path but nothing seems to work. I've also checked answers here and from other websites but nothing seems to solve my problem. It just does not make sense that my other FXML files under the same folder loaded well but not these three.
I think of the two following ways:
Make sure you set the path correctly. Anyway you should show us the folder system and how you set the path. Don't forget that the path starts from the current package, not the root of the project.
Clean and Build your project and run it again. It often somehow helps me to solve lots of issues.
I'm a novice at Java and eclipse IDE. I'm trying to create a plugin to my installed eclipse 4.4.0 by the official IBM article.
I've added plug-in description to the plugin.xml:
<extension point="org.eclipse.debug.core.launchConfigurationTypes">
<launchConfigurationType
name="MyConfiguration"
delegate="com.myplugin.first.launching.MyLaunchConfiguration"
modes="run, debug"
id="com.myplugin.first.launching.myConfiguration">
</launchConfigurationType>
</extension>
and I've created empty configuration delegate with required dependencies.
Unfortunately I cannot launch a new eclipse application with my plugin because every time I get the following error:
java.lang.NumberFormatException: For input string: ""
at java.lang.NumberFormatException.forInputString(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at org.eclipse.osgi.storagemanager.StorageManager.updateTable(StorageManager.java:511)
at org.eclipse.osgi.storagemanager.StorageManager.open(StorageManager.java:708)
at org.eclipse.osgi.storage.Storage.getChildStorageManager(Storage.java:1747)
at org.eclipse.osgi.storage.Storage.getInfoInputStream(Storage.java:1764)
at org.eclipse.osgi.storage.Storage.(Storage.java:124)
at org.eclipse.osgi.storage.Storage.createStorage(Storage.java:84)
at org.eclipse.osgi.internal.framework.EquinoxContainer.(EquinoxContainer.java:75)
at org.eclipse.osgi.launch.Equinox.(Equinox.java:31)
at org.eclipse.core.runtime.adaptor.EclipseStarter.startup(EclipseStarter.java:297)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:232)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:648)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:603)
at org.eclipse.equinox.launcher.Main.run(Main.java:1465)
at org.eclipse.equinox.launcher.Main.main(Main.java:1438)
An error has occurred. See the log file
null.
I have not found the log file with the error.
What's wrong? What should I do?
Maybe somebody knows the problem.
Try deleting everything in eclipse\configuration folder except config.ini and start your eclipse. Also paste the contents of the latest log file from eclipse\configuration for complete error.
Well! I,ve fixed the problem. I just created a new workspace and copied my project and config files to the workspace.
So the problem was in a broken workspace. I guess some workspace config file was corrupted. Anyway thank redoc for the idea.
I can't seem to launch a .jar file. An error comes up when I launch it. Help would be appreciated, here is the error:
CouldNotLoadArgumentException[ Could not load file/URL specified: C:\Users\Donavon\AppData\Local\Temp\javaws12]
at com.sun.javaws.Main.launchApp(Unknown Source)
at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
at com.sun.javaws.Main$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
First, please check if your TEMP folder is still there.
Second, if you can find jawaaws12 in there, move it to somewhere else. Then uninstall and re-install java. The appropriate file should be created automatically.
so I am having pretty much exactly the same problem as what someone else has described here:
birt-exchange.
I have integrated BIRT with my existing web application that requires the xerces jar (mine is version 2.5) and the following exception is thrown when I attempt to view the report:
java.lang.NullPointerException
at org.eclipse.birt.chart.reportitem.ChartReportItemImpl.doCompatibility(ChartReportItemImpl.java:302)
at org.eclipse.birt.chart.reportitem.ChartReportItemImpl.deserialize(ChartReportItemImpl.java:282)
at org.eclipse.birt.report.model.extension.PeerExtensibilityProvider.initializeReportItem(PeerExtensibilityProvider.java:582)
at org.eclipse.birt.report.model.elements.ExtendedItem.initializeReportItem(ExtendedItem.java:305)
at org.eclipse.birt.report.model.elements.ExtendedItem.doCheck(ExtendedItem.java:642)
at org.eclipse.birt.report.model.elements.ExtendedItem.checkCompatibility(ExtendedItem.java:604)
at org.eclipse.birt.report.model.parser.ModuleParserHandler.handleExtendedItemCompatibility(ModuleParserHandler.java:431)
at org.eclipse.birt.report.model.parser.ModuleParserHandler.endDocument(ModuleParserHandler.java:393)
at org.apache.xerces.parsers.AbstractSAXParser.endDocument(Unknown Source)
at org.apache.xerces.impl.XMLDocumentScannerImpl.endEntity(Unknown Source)
at org.apache.xerces.impl.XMLEntityManager.endEntity(Unknown Source)
at org.apache.xerces.impl.XMLEntityScanner.load(Unknown Source)
at org.apache.xerces.impl.XMLEntityScanner.skipSpaces(Unknown Source)
at org.apache.xerces.impl.XMLDocumentScannerImpl$TrailingMiscDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
at org.eclipse.birt.report.model.parser.ModuleReader.readModule(ModuleReader.java:94)
at org.eclipse.birt.report.model.parser.DesignReader.read(DesignReader.java:88)
at org.eclipse.birt.report.model.core.DesignSessionImpl.openDesign(DesignSessionImpl.java:315)
at org.eclipse.birt.report.model.api.SessionHandleImpl.openDesign(SessionHandleImpl.java:294)
at org.eclipse.birt.report.engine.parser.ReportParser.getDesignHandle(ReportParser.java:158)
at org.eclipse.birt.report.engine.api.impl.ReportEngineHelper.openReportDesign(ReportEngineHelper.java:255)
at org.eclipse.birt.report.engine.api.impl.ReportEngine.openReportDesign(ReportEngine.java:589)
at org.eclipse.birt.report.service.ReportEngineService.openReportDesign(ReportEngineService.java:383)
at org.eclipse.birt.report.utility.BirtUtility.getRunnableFromDesignFile(BirtUtility.java:594)
at org.eclipse.birt.report.context.ViewerAttributeBean.getDesignHandle(ViewerAttributeBean.java:654)
at org.eclipse.birt.report.context.ViewerAttributeBean.__init(ViewerAttributeBean.java:231)
at org.eclipse.birt.report.context.BaseAttributeBean.init(BaseAttributeBean.java:233)
at org.eclipse.birt.report.context.ViewerAttributeBean.<init>(ViewerAttributeBean.java:116)
at org.eclipse.birt.report.context.BirtContext.__init(BirtContext.java:44)
at org.eclipse.birt.report.context.BaseContext.<init>(BaseContext.java:69)
at org.eclipse.birt.report.context.BirtContext.<init>(BirtContext.java:30)
at org.eclipse.birt.report.servlet.ViewerServlet.__getContext(ViewerServlet.java:150)
at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.doPost(BirtSoapMessageDispatcherServlet.java:243)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:647)
I have successfully viewed the integrated demo report (included with the BIRT runtime download) with my existing application, but it did not include a chart, my report does. The stack trace indicates the chart is the difference between not working and working.
Does anyone have any ideas? I cannot remove the xerces jar since my existing app will fail to deploy. Is there anyway of effectively telling BIRT to ignore whatever other jars might be contained in the WEB-INF/lib directory?
In case it's relevant; my web app server is Tomcat 5.5.
I belive I have found the problem.
Under the directory WEB-INF/platform/plugins (where platforms is a BIRT specific directory) there is a jar named org.apache.xerces_2.9.0.v200909240008.jar.
I update my Xerces jar to version 2.9 and seems to be working...hope that helps anyone who may also hit this problem!
Got the same problem, in my case it turned out to a be an older version of Xerces on the classpath (2.4). Removing that one solved the problem.
After upgrading to the latest java version (Java 6 update 13) a webstart application that was being used in production environments for many years, stopped installing with the following error:
java.lang.Exception: cache failed forhttp://localhost:8080/ReactorStudio/studio/installer.jnlp
at com.sun.javaws.Launcher.updateFinalLaunchDesc(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.launch(Unknown Source)
at com.sun.javaws.Main.launchApp(Unknown Source)
at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
at com.sun.javaws.Main$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
The application jnlp is downloaded correctly and all the associated jar files. The application also contains a reference to an installer jnlp file that extracts a few files to the local disk the first the application is being run.
Any ideas on what is the problem, or how I could bypass this?
We had a similar issue when upgrading to the latest JRE. Our issue seemed to be related to this bug that should be fixed in 6u14. Perhaps your issue is also related.
The only workaround we found was to clear the webstart cache and launch the application again. In our experience this seems to be the solution to most webstart issues.
Try to remove href="..." from the "jnlp" tag of the "launch.jnlp" file.