Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to use Java.util, swing, the library packages?

Status
Not open for further replies.

ADO

Technical User
Jul 7, 2000
2
US
Hello,

I tried to use : import Java.util.*
but then inside the program the compilor can not find
the some name like DoubleGenerator...

I guess the reason is that I did not set the correct classpath, so I can not use swing, util and so on.

If that is the reason I think I have to add one expression
like set ClassPath=c:\jdk1.3\...don't know
in the AUTOEXEC.BAT file.

But what will the classpath supposed to be, any other reason for
this frustrating problem?

I really apprecite your help
Regards
Ado
 
When you go in dos command prompt, type
path c:\jdk1.3\bin
javac

in autoexec.bat file add
after existing other paths, if it is the last path do not put ;leave it open so windows can see other paths



 
To check and see if the classpath is set properly, you can type "set" without the quotes at a command prompt.


Swing and the other standard packages are located in a directory that java searches for automatically. You should be able to import them with no problem.


Maybe you could post the code you are having problems with and the tek-tip crews could take a look at it.

 
i notice you typed
I tried to use : import Java.util.*
i hope what you meant was
[tt]import java.util.*;[/tt]
an anoying thing is that the standard packages have lowercase letters yet the classes have the first letter capital
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top