Incompatible Types

633 byte By jyotishmana at 2007-9-28 19:25:35
Hi,I am pretty new to this wonderland of Java.Well,my questions is as follows:Assume that i have defined a String variable:String myString = "abcd";Now my goal is to create an arraylist with the same name as that of the value assigned to myString.That is the goal is to achieve:ArrayList abcd = ...

"Cannot resolve symbol" error

501 byte By will5a at 2007-9-28 19:27:59
Hello,I use EditPlus 2 for editing my classes and I 've got problem to compile them. I 'm sure my settings in EditPlus (User Tools) are corrects.I compile my class1 (for example) with javac and it prompt:Class1.java:65: cannot resolve symbolsymbol : class Class2private Class2 class2 = new ...

Language issues...

1232 byte By furrykefa at 2007-9-28 19:41:07
I tried to find info about this on the website or the official documentation, but I couldn't. The issue is this: I am using Windows XP and I have my computer's language set to Japanese. This is necessary for me to be able to type in Japanese (it isn't necessary for all apps, but it is for ...

"main" java.lang.NoClassDefFoundError

982 byte By JARRILUCEAa at 2007-9-28 19:41:11
Hi guys!I have a problem with have. I have just set up the following version of java http://java.sun.com/j2se/1.4.1/download.htmlSetup created the following folderC:\Program files\java\j2re1.4.1_02java.exe can be executed from anywhere on my hard disk (the path was setup accordingly)However, I ...

some help on tomcat !!!

661 byte By pi3141563a at 2007-9-28 19:46:35
I have put on my Windows 2000 Server these binariesfirstjdk1.3.1second apache 1.3.1thirdtomcat 4.2I have defined catalina_home et java_homeApache runs wellBUT, when I put on my browser http://localhost:8080/this error happensorg.apache.jasper.JasperException: Unable to compile class for JSPAn ...

call to super must be the first stmt in a constructor?

548 byte By FrancisANDREa at 2007-9-28 19:54:02
HiOn the following inheritance:import java.io.*;class Test extends File {Test(String path) {path = path.replace('.', '/');super(path);}Javac emits such error:Test(String path) { ^Test.java:5: call to super must be first statement in constructorsuper(path);Does anybody know why such ...

Similar error as java.lang.NoClassDefFoundError

1091 byte By spaceboyyanga at 2007-9-28 20:05:16
I wrote a package viewer, viewer.java is a main class, when i run it, the error is as follow. Anyone can help me to solve this problem. thanks.java.lang.NoClassDefFoundError: deegree/org/viewer/Viewer (wrong name: org/viewer/Viewer)at java.lang.ClassLoader.defineClass0(Native Method)at ...

problems on java.lang.NoClassDefFoundError

1537 byte By spaceboyyanga at 2007-9-28 20:05:43
The simple sourcecode is as followWhen I compile javac hellowporld.javajava helloworldthe error information is "Exception in thread "main" java.lang.NoClassDefFoundError: helloworld (wrong e: helloworld/helloworld)at java.lang.ClassLoader.defineClass0(Native Method)at ...

Possible to extract java version from the class file?

276 byte By lpoona at 2007-9-28 20:09:13
Is it possible to determine which version of Java compiler compiledthe class file from just the class file? I looked into decompilers,but the couple I looked at doesn't seem to provide this information.Any help would be greatly appreciated.

Yet another exe question

634 byte By JavaJosh86a at 2007-9-28 20:22:00
I know a lot of questions have been posted on this topic, but most were a few years old, and I was wondering if there was any new insight into the question of a byte-code to native-code compiler.I want to create an executable Win32 file that runs independantly of the JVM/JRE. My budget is ...

public Static Strings

595 byte By bilcoa at 2007-9-28 20:28:24
Hi,I have a class / interface (tried both) which containsStrings only.This class is referenced from numerous other classes,however, at compile time the String are copied intotheir calling location, so my class is never actually calledto get the value of the Strings.Is there anyway to stop the ...

created a exe file, what do i need for it to run oanother computer

228 byte By tellingja at 2007-9-28 20:41:48
I have made a exe file from a my java class, (don't know if it works cos it said something about not finding same file or another, but i ran ok).So I have the exe file, run exe, build exe. Do I need both of these?

problem with moving .java and .class files

709 byte By pascoe213a at 2007-9-28 20:54:58
Hello, I dont know if this is the right forum I am not sure which forum it should be in. I regularly write java code using Sun one on my home computer then copy the directory the .java and .class files are in to cd and take them to computers in the Uni I am at. I then copy the directory to the ...

cant execute java compiler?MSVCRT.DLL error

1254 byte By amitabh316a at 2007-9-28 21:11:59
Sir, I have a P4 processor with 256 MB RAM , 40 GB hd drive. Recently I have installed java software (tried with all versions one at a time) and I've encountered a typical problem. When i execute the java compiler or any file , except java.exe, I get the following error and I am unable to ...

compiling error

1131 byte By solace2ka at 2007-9-28 21:14:18
I've been playing with JDOM, trying to do some work with XML. My source file is in c:\test, which is where the jdom.jar file is as well.So to compile it, I'm typing (in c:\test) javac -classpath c:\test\jdom.jar HelloJDOM.javaI get the following error:HelloJDOM.java:10: cannot resolve ...

Keep getting API compiling errors

245 byte By MGT333a at 2007-9-28 21:28:21
I keep getting API errors and I am using a very current version of SDK.Keeps saying the API is deprecated, but the sources are from java boutique and the applets are pretty recent as well.What am I doing wrong?Michael

Javac : dependencies with packages (1.3.1 vs 1.4.1)

1670 byte By telloxa at 2007-9-28 21:33:28
Hello, With JDK 1.3.1, I used to compile my package-oriented projects simply by compiling the class that contains the main() method. Javac then compiled all the needed class files, depending on the java source files I had modified.Now I'm using JDK 1.4.1 and its new javac no longer recompiles ...

Help !! Client for session bean

301 byte By hanipala at 2007-9-28 21:58:54
I need your help for this roblem :I have deployed a session bean in helloClient.jar and wrote TestHello class to test the session bean.My problem ist to do this test ;i have tried with this command java -cp HelloClient.jar TestHello ,but it works not ...

Multiple class files for single java file

628 byte By JGeeka at 2007-9-28 22:08:01
HiI have put together a few applications, most of which live inside a single java file. One of these java files contains a private (inner) class called PathPanel. When I compile the java files, i get multiple class files for many of the classes that look like ...

No compiler after installation ?

400 byte By ncdevelopera at 2007-9-28 22:45:51
I had installed "j2sdk-1_4_2-beta-windows-i586" and after installation I had noticed that there is no javac.exe file. I could not type the javac command in dos shell due to this. am i missing something here ? I had last programmed in java more than a year back and now I am confused why there ...

Can't find class

1188 byte By manctma at 2007-9-28 22:47:42
I have installed the J2SE in C:\j2sdk1.4.1_02 directory. And then I add a path = C:\j2sdk1.4.1_02\binThen I make a file -- F:\Project\javatest\test.java.-import java.awt.Graphics;public class test extends java.applet.Applet{public void paint(Graphics g){g.drawString("Hello world", 20, 90);}}-in ...

Anyone suing MySQL with Cocoon?

1356 byte By austintashisa at 2007-9-28 22:48:52
I'm trying to get started with Cocoon because we have a couple of project where we need to publish reports in PDF and other formats, so I'm trying to get the database connectivity part working. I set up the database for the personnel example, set up the configurations and installed the MySQL ...

Windows/Linux -classpath flag seperator is different

370 byte By podollb1977a at 2007-9-28 22:58:27
When I am using the -classpath command line option the syntax is different on Windows vs Linux, this is a headache, anyone know why or a way around it?:Windows:javac -classpath "xxxx.jar;yyyy.jar" *.javaLinux:javac -classpath "xxxx.jar:yyyy.jar" *.javaI have verified that if tried the other way ...

sun.tools.javac.Main deprecated in 1.4

409 byte By bulcockca at 2007-9-28 23:01:59
I have a program which reads in a template from a file, converts it to Java source code and uses the sun.tools.javac.Main class to compile the source code. The code is similar to the way JSP works.With Java 1.4 I get a warning message saying: Note: sun.tools.javac.Main has been deprecated.Does ...

CompilerError: stackSize null

1675 byte By sunilkroy2a at 2007-9-28 23:10:25
Whan I am trying to compile a class in jdk1.1.6(which uses com.sun.java.swing package, I am getting this error:CompilerError: stackSize nullat sun.tools.java.Type.stackSize(Compiled Code)at sun.tools.tree.Context.declare(Compiled Code)at sun.tools.javac.SourceField.check(Compiled Code)at ...

The import javax.comm cannot be resolved!!!

698 byte By twikia at 2007-9-28 23:14:03
Hello, I have installed the javax.comm package as specified by the installation instructions (view: http://developer.java.sun.com/developer/JDCTechTips/2002/tt0122.html#tip2)SO my configuration is : Windows 2000 with j2sdk1.4.0 and Eclipse 2.1I have done this installation for the Communication ...

compile problem after transplant

506 byte By 2Bpencila at 2007-9-28 23:18:08
originally developed in Windows 2000now i'm trying to transplant to linuxerror occured when build client using anterror message is:client-compile:[mkdir] Created dir:/home/zyc/SPI_TOOLKIT_DEV/build-examples/client/classes [javac]Compiling 99 source files ...

Is it possible?

758 byte By microcata at 2007-9-28 23:27:29
My directory struct is:util.javapkg/test.java//util.javapublic class util{public static void show(){System.out.println("util.show");}}//test.javapackage pkg;public class test{public static void main(String args[]){util.show();}}First, I compile util.java:javac util.javaIt's ok.Then cd to ...

New to Java - Need Help

361 byte By Strataforce7a at 2007-9-28 23:30:34
Hi,I just downloaded the development kit and am having a problem. I wrote a simple program in notepad and went into the command window to compile it. But, for some reason, when I input the "javac" command, It just says "bad command or file name". I have tried this several times and I can't get ...

ANT build problem

832 byte By LightWinda at 2007-9-28 23:35:01
Hi, this may not be the correct place to discuss the topic. But pls help me on this:i create a simple java program that just displays text :Hello, ANT. I try to compile it using ANT version 1.5.1. On the screen, the ANT states that Building successful! But the class file is not created in my ...

'javac' Jollies!

786 byte By aitaia at 2007-9-28 23:35:31
Hi, AllRecently installed SDK1.4.1_02 (eng) on a Windows XP Professional (jap), with the following results when I run a compile command:C:\JAVA2>javac Analysis.java'javac' is not recognised as an internal or external command, operable program or batch fileThe PATH ...

same classpath executes but does not compile

654 byte By alexscottia at 2007-9-28 23:35:46
Hi All,this strange behavior happens.I have on a W2K dos console the CLASSPATH variable set to a certain value. I have a class that tries to import another class ( org.apache.xml.serialzer.Serializer ).1 javac MyClass.java raises the following error:MyClass.java:1: package org.apache.xml does ...

bad command killing me!

913 byte By Toby21a at 2007-9-28 23:39:35
I'm sure you've heard it before loads of times, when trying to compile using javac MyFirst.java I get 'bad command or file name'. But I have updated my path variable (i have win. ME and I tried adding to the autoexec.bat file and also through the environment tab the path ...

Compiling to native code

613 byte By ibradaca at 2007-9-28 23:56:54
HiIn order to improve the performance of a java application, we would like to compile the java code to native code for Solaris and Linux. The appplication is quite large and based on Swing. We experimented with 'gcj' but we found out that it does not work with Swing.Two questions arise:1. As ...

Compile in Server side of the client codes

288 byte By thureinnyoa at 2007-9-29 0:01:57
Hi everyone...What I need to do is to compile the codes which is sent from client in server side and run it.Is there anyway that can be done?I want to knowHow to load the compiler from server side?orHow to create class file at server side?

transferring java program onto HTML(applet)

2542 byte By ARiddlera at 2007-9-29 0:07:46
Hi everyone,I'm having trouble as the header states transferring a simple program onto HTMl.When I finshed compiling the *.java file to a *.class and set up a html file to reference it the following message comes up at the bottom of any explorer program i use.: HelloAgainApplet notinited As ...

Jar to EXE ?

411 byte By GEOHATa at 2007-9-29 0:10:21
I have a question since i have started to use Java! Is there any way to convert the jar files of Java to exe files, or to create an exe file with the JBulder when you creating a project? I find it complicated that you must install the JDK to a mashine first to run a Java Application and i think ...

error: can't find jre, error: registry values set to ver 1.4 but 1.3 is req

197 byte By shadow_of_vengencea at 2007-9-29 0:17:50
just got my dreamweaver program and since then my jre has been screwed. don't know how to fix it but that's why i am here. the errors are listed in the subject matter. thanx for your help.

I DO NEED HELP!!

303 byte By rick1001a at 2007-9-29 0:40:06
please, help. i'm working in Jcreator 1.5 and I tried to compile my servlet, but all I see is this: c:\etc...\myServlet.java: package javax.servlet does not exist import javax.servlet.*;and there lots of theses. I installed j2sdk1.4.0_02.please, help me, i'm really stuck! ...

how to sort data in a Vector

861 byte By 80113956a at 2007-9-29 0:55:00
hi,i want to create new class on fly. The simulator program (my main program) promts the user to enter class name and allows the user to enter the attributes and their types as well. The values accepted by user, will further be created on fly in form of a class.For example imagine a program ...

Impaired compiler

165 byte By Seapoliticoa at 2007-9-29 0:55:34
As i want to compile sth there is an error "Exception in thread "main" java.lang.NoClassDefFoundError: com/sun/tools/javac/Main".Any help wouldbe valuable....

"Error:cannot read:HelloWorldApp.java" message

198 byte By Seapoliticoa at 2007-9-29 0:58:06
As the caption says,after finding the file I want to compile and start compiling there is the message shown in the subject.Any help would have been valuable...The program is the HelloWorldApp

initialization error

297 byte By wclarke65a at 2007-9-29 0:58:42
I have installed the sdk 1.4.1 and then re-complied an old project that was created using the jdk 1.2 and I receive this errorinitialization error: class Error const *: class file has wrong version 48.0, should be 45.3 or 46.0.Can anyone advise? Did I forget to set

javac error, compiling

524 byte By simoninpertha at 2007-9-29 1:00:59
I have never compiled a class file, and have just go this error,dose it mean that I stuffed up in my script or javac isnt workin properly.dos_C:/j2sdk1.4.1_03\bin>javac AVIPviewer.javaAVIPviewer.java:1414: cannot resolve symbolsymbol: class JSObjectlocation : class AVIPviewerprivate JSObject ...

problem in compiling packages

958 byte By sosan20a at 2007-9-29 1:01:53
I am new to Java. I am currently using Java in developing a simple system. However, my system need to import other external classes.The main problem is i dont know how to compile this file when they are in separate folder (i am using windows). Let say the main .java is in one folder and other ...

PLease!!!!

416 byte By champagne10cfa at 2007-9-29 1:13:25
i found an erorr when i tried compiling using the j2sdk1.4.1_02. the porgram was running without error when i compiled in jdk1.3. may i know what is wrong. i have look into one of the message someone has posted earlier on but there is no answer for that.this is the error found:-Error #: 750 : ...

jdk1.3, Windows98 and packages

861 byte By lf_suna at 2007-9-29 1:33:41
Using jdk1.3 on Windows 98, this is what happens: I make a super class Person packaged in person and two subclasses Boy and Girl also packaged in person. Then I write a class that imports person.* and instantiates Boy and Girl. However, I get a series of 'Cannot resolve symbol' compilation ...

invalid method declaration; return type required?

350 byte By chriscmena at 2007-9-29 1:36:52
this is what I type in (the .java file is hello.java)(i put the .java file into my bin folder, but I am not sure I had to do that):-cd C:\j2sdk\binC:\j2sdk\bin>java hello.javahello.java:5: invalid method declaration; return type requiredmain(){^1 error--that is it, help me ...

Trouble compiling web service client file

1771 byte By NGInterfaceInca at 2007-9-29 1:47:32
Hi,I am trying to deploy a test web services implementation on JBoss 3.2.1 and Axis 1.1RC2. The problem is, I cannot even compile my client code (the one that invoke the web services)...it seems that the java compiler cannot locate the following packages:import ...

building PP 1.0 reference implementation

662 byte By platratesa at 2007-9-29 1:55:16
I'm trying to compile Personal Profile. I thought I followed the instructions in the PP-release-notes.html file to complile the RI. I'm getting an error. As root, in the linux-i686 directory I entered the command...make J2ME_CLASSLIB=personal ...