This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Product Version: NetBeans IDE Dev (Build 200809021401) Java: 1.6.0_10; Java HotSpot(TM) Client VM 11.0-b15 System: Windows XP version 5.1 running on x86; Cp1250; cs_CZ (nb) COS uses a java file location instead of package declaration for execiting files... To reproduce: 0. Start IDE 1. Open sample project from TS_60_JavaEditor and assure COS is enabled 2. Open class OpenFile.java 3. Try to run this file ("Run File" from the editor's popup menu) -> failure: java.lang.NoClassDefFoundError: test/OpenFile Caused by: java.lang.ClassNotFoundException: test.OpenFile at java.net.URLClassLoader$1.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:307) at java.lang.ClassLoader.loadClass(ClassLoader.java:252) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) Could not find the main class: test.OpenFile. Program will exit. Exception in thread "main" Java Result: 1 4. Disable COS for the project 5. Try to run file OpenFile.java again -> success
Created attachment 69043 [details] sample project
*** Issue 166307 has been marked as a duplicate of this issue. ***
Should be fixed in the current dev build.
Yes, it works in the 68Beta => Verified