Okay, so I fooled around and made this out of examples I found and I put my revised code from last week with it. How do I get my GUI code into a GUI format? I wrote this put it will not make a GUI image.
I get errors:
java.lang.NoClassDefFoundError: ofelia_inventory_4/Ofelia_Inventory_4 (wrong name: Ofelia_Inventory_4/Ofelia_Inventory_4)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.security.AccessController.doPrivileged(Native Method)
Exception in thread "main" Java Result: 1
BUILD SUCCESSFUL (total time: 0 seconds)
When I debug with my program.
Here's the rest of the program if you need it. I'm sorry to do this, I know you guys get tired of all this long code:
It probably doesn't have anything to do with Swing. Looks like a wrong name of the package or directory.
I'd suggest renaming the package to not contain upper case letters at all and also remove underscores (it is probably legal, but very usunual). So your package name could be ofeliainventory4. The rename the directory containing your class to ofeliainventory4 as well.
For your main class I'd also suggest to use a name different from package name, more than in just letter case. You can rename your class just to Main, or perhaps OfeliaMain if you must. The reason is that at this time, when you see Ofelia_Inventory_4 in some error message, it isn't immediately clear whether the error pertains to the package or to the class.
Then rebuild your entire project and try to run it again.