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 = ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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.
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 ...
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 ...
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?
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 ...
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 ...
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 ...
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
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 ...
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?
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 ...
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 ...
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.
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! ...
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 ...
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....
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
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
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 ...
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 ...
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 : ...
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 ...
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 ...
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 ...
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 ...