Windows xp and Java SDK
Hey
I just got a new computer with Windows XP on it and I installed Java SDK on it. I can compile my programs but I can't run them i get this:
Exception in thread "main" java.lang.NoClassDefFoundError: hate
even though there is a .class file. I was wondering if anybody have the same problem?
Thanks
Do a "echo %CLASSPATH%" at the DOS prompt...You should see the directory in which you installed Java...
Example:
CLASSPATH=c:\j2sdk1.4.1;.; where (".") = the current directory.
Your JVM cannot find the class file because you have not set the CLASSPATH enviroment variable. Your PATH enviroment variable sounds like it is ok because your OS(Windows, etc) is able to find the java, javac, jar, etc commmands.
Hope this helps.
Similar Messages
-
Whats is difference between Java JRE and Java SDK
Hi,
what is the difference between Java JRE and Java SDK...
i think both of them have the same set of files to be installed...
I am not able to understand where they differThe JRE (Java runtime Environment) contains just the stuff necessary to run Java and the SDK (System Development Kit) contains the extra stuff necessary (and also helpful) to develop in Java.
-
Windows XP and java.lang.NoClassDefFoundError: Console
Our company is currently using a web page to launch a java applet that redirect the user to an application server to demo our product. This has been and still is working fine for all Windows version until XP. And depending on which version of XP, sometimes it will work and sometime it won't. The link to the web site to launch the applet is http://www.aasys.com/gs_java/iejava.htm if you wish to test it.
It should take you to a screen asking for a security code which we would provide to our customers. If you get this far it is working.
Any suggestion would be helpful.
Thanks.
DP Grose
Below is the error message we get on some of the Windows XP versions :
Java(TM) Plug-in: Version 1.4.2
Using JRE version 1.4.2 Java HotSpot(TM) Client VM
User home directory = C:\Documents and Settings\Don
Proxy Configuration: No proxy
c: clear console window
f: finalize objects on finalization queue
g: garbage collect
h: display this help message
l: dump classloader list
m: print memory usage
o: trigger logging
p: reload proxy configuration
q: hide console
r: reload policy configuration
s: dump system properties
t: dump thread list
v: dump thread stack
x: clear classloader cache
0-5: set trace level to <n>
java.lang.NoClassDefFoundError: Console
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
at java.lang.Class.getConstructor0(Unknown Source)
at java.lang.Class.newInstance0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at sun.applet.AppletPanel.createApplet(Unknown Source)
at sun.plugin.AppletViewer.createApplet(Unknown Source)
at sun.applet.AppletPanel.runLoader(Unknown Source)
at sun.applet.AppletPanel.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)Your first option we are currently looking at but have not tested it yet. We would prefer the end user not to have to do this, but they may have to in the end.
Your second option seems the best route to go and we may be able to get the source code from our vendor. Once this is compiled under 1.4.2 will it still be compatable with the older version of MS JVM or will our users need to download the current Java plugin? Since this the way that Java is proceeding this will most likely work for everyone.
Thanks. -
Windows 7 and java sometimes start or sometimes not
Hello!
I have problem when i go to this url :http://javatester.org/version.html java starts on my computer. But when i try to open next ie and again enter page java not starts... but int 3 ie java starts again, in 4 again, in 5 not.... Random
This problem is independ java version but only appears on windows7....
What can be a problem?user8672998 wrote:
See your self if you have win7I do.
The laptop I'm typing this on is an older Toshiba laptop that started with MS Windows Vista and now is running Win7 Enterprise.
The issue doesn't appear here. Ever.
Although I rarely use I.E., the JVM always starts when needed.
I more commonly use Mozilla's Firefox browser.
This computer initially had Firefox 3.x installed to it, but it recently had that upgraded to Firefox 7.x -
Hi there,
I'm currently converting a C++ application into Java.
My main problem is that the C++ application uses windows messages to communicate between functions.
For the C++ users it uses SendMessage() and PostMessage() methods to do this.
My main question is, is there a equivalent in Java to do this, so sending and retrieving windows messages in Java.
Thanks in advance....Sorry, you're confusing me (not that it's hard to do).
You're throwing out "application", "server", and "client" in such a way that it's hard for me to understand exactly what you're doing.
When you say "server", it makes me think of a Java app that is started and stays up, listening on a particular port for a particular protocol. Other machines on the network are the "clients" in this case. They agree to send messages using the agreed-upon protocol to the "server" listening on that port.
"send and catch messages between programs" doesn't sound like they're running in the same JVM. These sound like networked objects.
You can use Java's RMI to set up distributed objects that use RMI-IIOP as the default protocol.
Is that what you want? -
Hey,
I have been testing my applications I have written in java since Windows 7 RC's had first started being released.
Finally after installing the retail ultimate edition... the results from Java GUI related stuff is still as it was since Windows 7's first release.
Resizing of JFrame's gives a serious flicker on GUI especially when using substance look and feel, (black background beneath the standard gui)
For example, resizing net beans in xp is perfect, but resizing it in Windows 7 gives a black background and an extremely slow repaint.
I hope this gets resolved soon... is there anything being done or some sort of work around?
thanks!
javdaxhii,
nb supported Vista on "http://www.netbeans.org/community/releases/67/relnotes.html#system_requirements",
1/ be sure that's win7 is 1.st service pack for Vista, nothing else, vista core 6.0 and win7 core 6.01,
2/ xp and vista is strict only 32-b,
3/ have you win7 - 32-b, or 64-b
4/ JVM 6 for 32-b or 64-b "http://java.com/en/download/faq/java_win64bit.xml"
5/ check if is JDK and SDK correctly instaled, (JDK 6)
6/ nb correctly runs on win2003 64-b(xp core) or win2008 64-b (vista core), JVM 6, JDK 6, JDK 5,
or
7/ instal that's on xp mode
... kopik -
A contact of mine is trying to learn java programming and has started with the Herbert Schildt book Java A Beginners Guide.
His OS is Windows Vista onto which he has installed NetBeans and Eclipse.
He has asked me for help but even though I am a programmer I only use Linux so am not sure that my Vista skills are adequate other than fixing his PATH environment.
His Java version is:-
java version "1.6.0_18"
Java(TM) SE Runtime Environment (build 1.6.0_18-b07)
Java HotSpot(TM) Client VM (build 16.0-b13, mixed mode, sharing)
His 1st program is:-
/* This demonstrates a variable.
call this file Example2.java.
Class Example2 {
public static void main(String args[ ]) {
int var1; // this declares a variable
int var2; // this declares another variable
var1 = 1024 // this assigns 1024 to variable 1
System.out.println("var1 contains" + var1);
var2 = var1 / 2;
System.out.println("var2 contains var1 / 2: ");
System.out.println(var2);
}but
javac Example2
error: Class names, 'Example2', are only accepted if annotation processing
is explicitly requested
How does he fix this?
BTW The above compiles and runs fine on my Ubuntu system....Smile
Regards,
Alf Stocktonstraygrey wrote:
Class Example2 {
Are you sure that's an upper-case C? If it is, then it's wrong.
javac Example2
error: Class names, 'Example2', are only accepted if annotation processing
is explicitly requested"javac" expects file names, "java" expects class names.
How does he fix this?
BTW The above compiles and runs fine on my Ubuntu system....SmileWith which command? -
BOXI 3.1 SP2 and java sdk documentation and api refs
I have a question regarding the status of the java api references for BOE, REPENG, RAS:
Yesterday we upgraded the 3.1 system from build 12.1.0882 to 12.2.099.BOE_Titan_SP_REF, which is XI 3.1 SP2.
When we look at SDK documentation in the Business Objects Community Network (former Diamond) we see that the api refs are still from July 2008.
Can you tell if we can get a more current api ref documentation for BO Enterprise, Report Engine and Report Application Server SDK anywhere else?
Thanks,
BerndThe only references and documenation is [here|http://www.sdn.sap.com/irj/boc/sdklibrary]
Typically new methods and such are not introduced in a current product version so most likely nothing has changed in the SDK. It does sometimes happen and when it does new documenation is usually released.
Jason -
Java Communications API and Java SDK 1.4.2
I just installed the Java Communications API 2.0 on my Windows XP system, with JDK 1.4.2. As per the install instructions, I copied files from the zip into my /lib and /bin directories and set the classpath. However, when I attempt to compile any of the samples, the compiler displays a large number of errors. I know the API documentation only references JDK1.2 -- are there any special tricks to installing on newer JDKs, or will I need to acquire an older JDK to develop?
My path variable is still not being set! Here is the content of my autoexec.bat located on the root directory of C:\
rem - By Groove Setup
PATH=%PATH%;"C:\Program Files\Groove Networks\Groove\Bin"
PATH=%PATH%;C:\PROGRAM FILES\J2SDK1.4.2_07\BIN
/code]
When I type 'path' at the MSDOS C:\ prompt, I receive the following in the get the following:C:\WINDOWS;C:\WINDOWS\COMMAND;\C:\PROGRAM FILES\GROOVE NETWORKS\GROOVE\BIN
As an aside, I noticed that when I perform a search of the my hard drive (c:\), I find two autoexec.bat files. One at the root, and the other in C:\Windows\Command\EBD.
I believe the instructions stated to modify the autoexec.bat at the root directory.
TIA for any assistance. This is really becoming a nusance and taking up quite a bit of my time trying to resolve this problem. -
Windows xp and java.exe problem
Hello all..
I tried to execute have a batch file consisting a jar file and classes in windows xp platform. I used j2sdk1.4.0_03. All my classes are stored in : C:\MyDocument\Softwares\classes directory
and the jar files are in: C:\MyDocument\Softwares.
I wrote the following commands in the batch file:
java -classpath C:\MyDocument\Softwares\classes;
C:\MyDocument\Softwares\jexcelapi.jar mainClass
When I lauched that batch file, a message came out:
java.exe has encountered a problem and needs to close. We are sorry for the inconvenience.
Could you tell me where the problem is and why? Do I need windows xp patch to eliminate the problem? And where can I find that patch?
Thanx for any suggestions...
RichardThanks for your comments. I have tried to reinstall the J2SDK, but then another error message appeared:
Error occured during the initialization of VM
java/lang/NoClassDefFoundError:java/lang/Object
I've checked my Path and it's set as following:
C:\j2sdk1.4.0_03\bin;
and my classpath setting:
C:\MyDocument\Softwares;C:\MyDocument\Softwares\classes;C:\j2sdk1.4.0_03\lib;
When I tried to execute the java command in any directory (inclusively in C:\MyDocument\Softwares) I always got that message. The only directory where I was able to run the command is in C:\j2sdk1.4.0_03\bin;
Before I did the reinstallation, I never had such a problem.
Have any hits? Thanks in advance.. -
Synchronized between Windows File and Java
Hi' could anyone help me..i have problem like this :
i have folder named javatutorial in my C:\ , i try rename that folder name into myjavatutorial and read the new name (both operation rename and read using my java program)
this is my code :
File x = new File("C:\\javatutorial");
x.renameTo(new File("C:\\myjavatutorial"));
System.out.println(x.getName());why java always print the old folder name?
if i see it in windows explorer the folder name already change. Why Java cannot synchronized between the new name and the old name? what i want java can print the new folder name...how to implement this?
i hope my question easy to understand...
thanks a lot...public myProgram()
File x = new File("C:\\javatutorial");
x.renameTo(new File("C:\\myjavatutorial"));
File[] file = x.listFiles();
for (int i = 0; i < file.length; i++)
System.out.println(file[i]);
if between x and C:\javatutorial have the same path, it will print :
C:\javatutorial\a
C:\javatutorial\bNo it won't because it won't compile.
This will:import java.io.File;
public class RenameEg {
public static void main(String[] args) {
File x = new File("C:\\javatutorial");
x.renameTo(new File("C:\\myjavatutorial"));
File[] file = x.listFiles();
for (int i = 0; i < file.length; i++) {
System.out.println(file);
}With the following outputC:\>dir javatutorial
Volume in drive C is IBM_PRELOAD
Volume Serial Number is 400B-A170
Directory of C:\javatutorial
28/09/2006 07:06 p.m. <DIR> .
28/09/2006 07:06 p.m. <DIR> ..
28/09/2006 07:06 p.m. <DIR> a
28/09/2006 07:06 p.m. <DIR> b
0 File(s) 0 bytes
4 Dir(s) 6,705,012,736 bytes free
C:\>javac -cp . RenameEg.java
C:\>java -cp . RenameEg
Exception in thread "main" java.lang.NullPointerException
at RenameEg.main(RenameEg.java:10)
C:\>dir javatutorial
Volume in drive C is IBM_PRELOAD
Volume Serial Number is 400B-A170
Directory of C:\
File Not FoundYou get the null pointer exception because listFiles() returns null. It
returns null becuse the folder had its name changed.
To list the files of the renamed folder, you will have to create a new File
based on the new (changed) name. -
Hi,
If I install Windows XP over my Windows 98 will my dos be taken off the system? And if so how would I run my Zava apps from a dos prompt?
ThanksHi,
If I install Windows XP over my Windows 98 will my dos
be taken off the system? And if so how would I run my
Zava apps from a dos prompt?
ThanksI mean, how would I run my Java apps! not Zava apps -
Hi,
i have a problem with NumberFormats and languages on a Windows system:
i want to have (for example) English GUI texts (i made some GUI forms using the IntelliJ GUI designer),
but i want to have the NumberFormat from the Windows locale (for example German/Swiss format).
The switching between the text languages works well, but i have to use -Duser.language for that purpose since only
then the GUI designer is able to use the correct gui_de or gui_en.properties file.
The problem now is that Locale Default = Locale.getDefault(); does not return the language from the Windows settings,
but the language from the -Duser.language setting which i gave the VM. Ok, its logical.
But i need the "initial" language from the Windows locale (the one its been before the -Duser.language overwrites the language)...
regards
BBThe switching between the text languages works well, but i have to use -Duser.language for that purpose since only
then the GUI designer is able to use the correct gui_de or gui_en.properties file.due to-Duser.language you will not get the correct Default Locale.
For workaround u can try below solution
Sync. your System Locale setting with -Duser.language and it is logically true.
If your System Locale is en_US
then your VM optional argument should be -Duser.language=en
if your System Locale is fr_FR
then your VM optional argument should be -Duser.language=fr
I think it will be solve your problem. -
Migration from Crystal IX to BO-XI using java sdk-- very urgent
Post Author: Pranav.Sharma
CA Forum: Migration to XI R2
Need help in migration from Crystal Report IX to BO-XI.
Currently we are using CR IX and Java SDK to access reports from J2ee application. These reports reside on remote server where we have shared access to that directory.
We are accessing these reports through our j2ee application.Can anyone please elaborate whether we can use same SDK here with slight change in code probably in authentication related to CMS etc and calling mechanism or we have to go for BO java SDK alltogether. Is anything we are missing here?
Can anyone please help as we have to complete migration in 1-2 days.The first thing you will want to do is to publish all of your reports to Business Objects XI and make sure they all still work. Obviously they won't have the dynamic parameters anymore but you should just ensure they all work and are able to connect to their databases. You can use a tool like the publishing wizard to help you.
All the reports should now be available inside of XI.
Unfortunately you will need to manually modify all of the 400 reports to use the business objects Dynamic Cascading Parameters DCP.
There should be some DCP info in the Business Views documentation.
I hope this helps
Rob Horne<br /><a href="/blog/10">Rob's blog - http://diamond.businessobjects.com/robhorne</a> -
Why we have separate azure java SDK for linux and windows
I saw different links for downloading azure java SDK for linux and windows.
What difference does it actually have when java is platform independent? Or both are same jars?Hi,
Thank you for your post.
It contains the same jar files.
Regards,
Mekh.
Maybe you are looking for
-
All songs in itunes not playing
A few real bad problems here! 1. I am running Itunes 12.0.1.26 on a PC with Windows 8.1 it's a Dell. *after almost a year of trouble recovering all of my playlists that had gone missing due to an itunes error I was happy to find myself two days a
-
Additional cost for finished goods
Hi all, Here we are following fifo method valuation. we are using SAP B1 2007B PL 04. I have a doubt how do we account the additional cost like Rent, Electricity etc. and What G/L Account need to specify at determination level. Here we are determing
-
How to make a Input Field with multiple lines?
hey folks, i need to make a popup window or a dynpro with 2 input fields, where the user can write on multiple lines. why isnt there such an input field in the screen painter? how can i make this? if i can do this with a dynpro it would be nice but a
-
Please help needed os x lion I wish to transfer photos from the iPhoto library to a album or folder then delete them from the Library but when I do this it also deletes them from the album ? how do I do this please.
-
when i search for websites on google, tahoo. bing once the list comes up and i select one it pops up as a notepad text window and the download window also pops up. i can't get to the website i choose.