• Post Reply Bookmark Topic Watch Topic
  • New Topic

Getting started  RSS feed

 
Shawn Stroud
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to use a java extension package (javax.swing) so I can import the JOptionPane GUI. The compiler doesn't locate it and I've tried changing the path to directories where I have all the libraries. I am not sure how to search for it since it doesn't have a standard file format (javax.swing.JOptionPane).
Any suggetions? "Give up" is not acceptable
SS
 
Tom Ben
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How are you trying to access it in your code? Can you paste a copy of your program or atleast the portion that you are having an issue with?
Originally posted by Shawn Stroud:
I am trying to use a java extension package (javax.swing) so I can import the JOptionPane GUI. The compiler doesn't locate it and I've tried changing the path to directories where I have all the libraries. I am not sure how to search for it since it doesn't have a standard file format (javax.swing.JOptionPane).
Any suggetions? "Give up" is not acceptable
SS


------------------
Sun Certified Programmer on the Java 2 Platform
 
Shawn Stroud
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The code for my JOptionPane looks like this - doesn't seem complicated. I've compiled at the C prompt before but not using swing package.
import javax.swing.JOptionPane;
public class Analysis
{public static void main ( String args [] )
{int attempts = 0,
goalsmissed=0,
player=1
result;
String input,
output;
 
Tom Ben
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I created and compiled a class ok with just importing the JOptionPane. What version of the jdk are you using?
Originally posted by Shawn Stroud:
The code for my JOptionPane looks like this - doesn't seem complicated. I've compiled at the C prompt before but not using swing package.
import javax.swing.JOptionPane;
public class Analysis
{public static void main ( String args [] )
{int attempts = 0,
goalsmissed=0,
player=1
result;
String input,
output;

 
Shawn Stroud
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Im using 1.3.1 and also have the Java2 platform. I have classes and libraries in the following directories:
C:\CoreJava
C:\InstantJavaBook
C:\JavaByExampleBook
C:\JDK1.3.1
C:\JustJavaBook
ALL that and I can't find javax.swing!...
Shawn
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!