From sbalkau at gmail.com Wed Feb 1 04:18:26 2006 From: sbalkau at gmail.com (Sascha Balkau) Date: Wed, 1 Feb 2006 18:18:26 +0900 Subject: [Java] Exception in thread "main" java.lang... Message-ID: <007d01c62710$7b6c8f70$0600a8c0@lara> Hi list, I already have a question too ... When I try to run a compiled Java class from the DOS prompt (Windows) I always get the following error: Exception in thread "main" java.lang.NoClassDefFoundError: Foo/class This doesn't happen if I build/run from the Eclipse IDE. Could somebody tell me what the problem is? I'm rather new to Java. Sascha From liguorien at hotmail.com Wed Feb 1 07:31:19 2006 From: liguorien at hotmail.com (=?iso-8859-1?Q?Nicolas_D=E9sy?=) Date: Wed, 1 Feb 2006 07:31:19 -0500 Subject: [Java] Exception in thread "main" java.lang... References: <007d01c62710$7b6c8f70$0600a8c0@lara> Message-ID: Hi Sascha, The classpath doesn't seem defined. What is the command you're using to launch the application ? Nicolas ----- Original Message ----- From: "Sascha Balkau" To: Sent: Wednesday, February 01, 2006 4:18 AM Subject: [Java] Exception in thread "main" java.lang... > Hi list, > I already have a question too ... > > When I try to run a compiled Java class from the DOS prompt (Windows) I > always get the following error: > Exception in thread "main" java.lang.NoClassDefFoundError: Foo/class > > This doesn't happen if I build/run from the Eclipse IDE. Could somebody > tell > me what the problem is? I'm rather new to Java. > > Sascha > > > _______________________________________________ > Java mailing list > Java at osflash.org > http://osflash.org/mailman/listinfo/java_osflash.org > From sbalkau at gmail.com Wed Feb 1 09:41:46 2006 From: sbalkau at gmail.com (Sascha Balkau) Date: Wed, 1 Feb 2006 23:41:46 +0900 Subject: [Java] Exception in thread "main" java.lang... Message-ID: <002b01c6273d$a2734730$0600a8c0@lara> simply java Foo.class. Where and how would I have to define the classpath? > > >> The classpath doesn't seem defined. What is the command you're using to >> launch the application ? >> >> Nicolas >> >> ----- Original Message ----- >> From: "Sascha Balkau" >> To: >> Sent: Wednesday, February 01, 2006 4:18 AM >> Subject: [Java] Exception in thread "main" java.lang... >> >> >>> Hi list, >>> I already have a question too ... >>> >>> When I try to run a compiled Java class from the DOS prompt (Windows) I >>> always get the following error: >>> Exception in thread "main" java.lang.NoClassDefFoundError: Foo/class >>> >>> This doesn't happen if I build/run from the Eclipse IDE. Could somebody >>> tell >>> me what the problem is? I'm rather new to Java. >>> >>> Sascha >>> >>> >>> _______________________________________________ >>> Java mailing list >>> Java at osflash.org >>> http://osflash.org/mailman/listinfo/java_osflash.org >>> >> >> _______________________________________________ >> Java mailing list >> Java at osflash.org >> http://osflash.org/mailman/listinfo/java_osflash.org From liguorien at hotmail.com Wed Feb 1 09:55:32 2006 From: liguorien at hotmail.com (=?iso-8859-1?Q?Nicolas_D=E9sy?=) Date: Wed, 1 Feb 2006 09:55:32 -0500 Subject: [Java] Exception in thread "main" java.lang... References: <002b01c6273d$a2734730$0600a8c0@lara> Message-ID: ok, you just have to remove the .class extension in the class name. >java Foo The classpath is defined with the -cp parameter : java -cp some_folder;another_folder MainClass But I don't think this is necessary in your case, the problems is with the class extension :) Nicolas ----- Original Message ----- From: "Sascha Balkau" To: Sent: Wednesday, February 01, 2006 9:41 AM Subject: Re: [Java] Exception in thread "main" java.lang... > simply java Foo.class. > Where and how would I have to define the classpath? > > >> >> >>> The classpath doesn't seem defined. What is the command you're using to >>> launch the application ? >>> >>> Nicolas >>> >>> ----- Original Message ----- >>> From: "Sascha Balkau" >>> To: >>> Sent: Wednesday, February 01, 2006 4:18 AM >>> Subject: [Java] Exception in thread "main" java.lang... >>> >>> >>>> Hi list, >>>> I already have a question too ... >>>> >>>> When I try to run a compiled Java class from the DOS prompt (Windows) I >>>> always get the following error: >>>> Exception in thread "main" java.lang.NoClassDefFoundError: Foo/class >>>> >>>> This doesn't happen if I build/run from the Eclipse IDE. Could somebody >>>> tell >>>> me what the problem is? I'm rather new to Java. >>>> >>>> Sascha >>>> >>>> >>>> _______________________________________________ >>>> Java mailing list >>>> Java at osflash.org >>>> http://osflash.org/mailman/listinfo/java_osflash.org >>>> >>> >>> _______________________________________________ >>> Java mailing list >>> Java at osflash.org >>> http://osflash.org/mailman/listinfo/java_osflash.org > > > _______________________________________________ > Java mailing list > Java at osflash.org > http://osflash.org/mailman/listinfo/java_osflash.org > From sbalkau at gmail.com Wed Feb 1 10:01:54 2006 From: sbalkau at gmail.com (Sascha Balkau) Date: Thu, 2 Feb 2006 00:01:54 +0900 Subject: [Java] Exception in thread "main" java.lang... References: <002b01c6273d$a2734730$0600a8c0@lara> Message-ID: <003a01c62740$72dffd30$0600a8c0@lara> Yes that was the prob! It only works without .class suffix! Thanks alot Nicolas! -Sascha ----- Original Message ----- From: "Nicolas D?sy" To: Sent: Wednesday, February 01, 2006 11:55 PM Subject: Re: [Java] Exception in thread "main" java.lang... > ok, you just have to remove the .class extension in the class name. > >>java Foo > > The classpath is defined with the -cp parameter : > > java -cp some_folder;another_folder MainClass > > But I don't think this is necessary in your case, the problems is with the > class extension :) > > Nicolas > > > ----- Original Message ----- > From: "Sascha Balkau" > To: > Sent: Wednesday, February 01, 2006 9:41 AM > Subject: Re: [Java] Exception in thread "main" java.lang... > > >> simply java Foo.class. >> Where and how would I have to define the classpath? >> >> >>> >>> >>>> The classpath doesn't seem defined. What is the command you're using >>>> to >>>> launch the application ? >>>> >>>> Nicolas >>>> >>>> ----- Original Message ----- >>>> From: "Sascha Balkau" >>>> To: >>>> Sent: Wednesday, February 01, 2006 4:18 AM >>>> Subject: [Java] Exception in thread "main" java.lang... >>>> >>>> >>>>> Hi list, >>>>> I already have a question too ... >>>>> >>>>> When I try to run a compiled Java class from the DOS prompt (Windows) >>>>> I >>>>> always get the following error: >>>>> Exception in thread "main" java.lang.NoClassDefFoundError: Foo/class >>>>> >>>>> This doesn't happen if I build/run from the Eclipse IDE. Could >>>>> somebody >>>>> tell >>>>> me what the problem is? I'm rather new to Java. >>>>> >>>>> Sascha >>>>> >>>>> >>>>> _______________________________________________ >>>>> Java mailing list >>>>> Java at osflash.org >>>>> http://osflash.org/mailman/listinfo/java_osflash.org >>>>> >>>> >>>> _______________________________________________ >>>> Java mailing list >>>> Java at osflash.org >>>> http://osflash.org/mailman/listinfo/java_osflash.org >> >> >> _______________________________________________ >> Java mailing list >> Java at osflash.org >> http://osflash.org/mailman/listinfo/java_osflash.org >> > > _______________________________________________ > Java mailing list > Java at osflash.org > http://osflash.org/mailman/listinfo/java_osflash.org