• Post Reply Bookmark Topic Watch Topic
  • New Topic

Getting an error when running some Java code  RSS feed

 
Matthew Yeend
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm trying to make a Java project that loads and displays an X3D file, the code that I have in the java class is:



I've downloaded all the Jars that I need and have made a library and linked that library to my project and I've put the 'test.x3dv' file in the project folder. The error that I'm getting when I run the code is:

 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 37465
539
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"TRUE" is a String. A boolean is true or false. Notice how they don't have quotes.

Making that line:
 
Matthew Yeend
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've changed it so that all the ones that have "TRUE" at the end are boolean and I have the following output when I run it.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 37465
539
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Progress! Can you show the command you are using to run it? IN particular, that you have a -cp flag and are including the jar that contains org.j3d.aviatrix3d.DrawableSurface.
 
Matthew Yeend
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm using Netbeans to write the code it so when I want to run it, I press the 'Run Project' button at the top. I found that jar here. I'm including all the jars that are stated here
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 37465
539
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You might want to try refreshing the NetBeans project. Or post a screenshot showing the jar in the NetBeans project path. Beyond that, I don't know. I've added this to the IDEs forum so someone who knows NetBeans better can weigh in.
 
Matthew Yeend
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've just refreshed the project and when I've run it, I've got:


The library that I've put the jars in can be found with the following link
 
Matthew Yeend
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 37465
539
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
All: The link works if you click on it: image
 
Matthew Yeend
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry, I didn't know how to make the image links work
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!