Execution

4347 byte By damoreallya at 2007-10-1 7:54:21
After I have compiled a file using the following code i then want to execute it and display the output or a frame by executing it but it won't execute can somebody help please?public void compile(){try{ //classpath = "set classpath=C:/Program Files/j2sdk1.4.0/bin/"; javacPath = "C:/Program ...

How to Store compile time errors in a file - using Main.compile(args)

393 byte By valyettana at 2007-10-1 7:57:45
import com.sun.tools.javac.Main;String Args[] = { "-classpath", ".;C:/j2sdk1.4.2_05/bin;", "-nowarn", fileName};I am using the command Main.compile(Args); to compile a Java File.It will return 0, if the file is compiled without errors. If errors exist, I want to store the errors in file. How to ...

a compiling problem

1412 byte By christograya at 2007-10-1 7:58:23
hi,I'm getting back into java after a long break and trying to learn j2ee ejb to make things extra difficult! I passed the SCJP exam over 3 years ago but haven't done much java since as my work took me along a different road.. anyway I'm trying to compile the first example from O'reilly ...

newbie: jsp compile error w/ tomcat 5.0.19

1802 byte By sirpelidora at 2007-10-1 8:11:20
Hello there, this is my first time try to write something in jsp/ servlets, and i encounter a minor installation problem:using mdk linux with j2sdk1.4.2 (locate at /usr/local/), tomcat is also locate at /usr/local.I am able to see HelloServlet.java, and HelloWorld.html at ...

error with my program: 'class' or 'interface' expected

1808 byte By HDesai1181a at 2007-10-1 8:12:17
below is the program i have written and i have no clue as to why i keep getting this error message: 'class' or 'interface' expectedimport java.io.*;import java.util.*;public class parity{public int even;public int [] check;public int parity(int[] a){even=0;check=a;}}public static void ...

HELP!

1899 byte By HDesai1181a at 2007-10-1 8:12:34
I'm a computer science student currently taking Data Structures and Algorithms II and my professor is making the class write a series of programs he found on the internet which were used in programming contests. I'm totally stoked on where to start with this one problem. Actually I'm totally ...

where to put extracted jfreechart folder

332 byte By ARawata at 2007-10-1 8:14:39
Hi,I had extracted jfreechart zip file but when I m compiling my java class , compiler gives errors like "package org.jfree.chart.ChrtFactory" does not exist and for other packages also.Please tell me how to map it to jar files?Please reply me as soon as possible.Thanks & ...

Exception in thread "main" java.lang.NoClassDefFoundError

397 byte By ajesha at 2007-10-1 8:19:59
hi,i am very much frustrated due to this problem.when i try to run any java program from command line i'm getting this same error.and these programs worked perfect in my friends pc.earlier i used netbeans IDE then these programs worked well.but now due to some problems now i'm getting the ...

HELP - problem in running

2259 byte By wjdhussain@yahoo.coma at 2007-10-1 8:20:10
I am using JBuilder 7. and have set all paths including library J2SDK1.4.2.I have complied a java project which include swing components.This project was previously compiled and run many time successfully. But few days i did not run on my pc.I have tested this project on my friends pc and there ...

size optimize

216 byte By prsgrstna at 2007-10-1 8:23:18
Hi,I have a applet I want to optimize on size.Can javac do size/speed optimizing in the way a c-compiler does?Is there any tool that size optimizes the bytecode?Thanks for any help.

Compiling Error

483 byte By Tsia at 2007-10-1 8:26:23
I know this has been asked several times, but I have been unable to find a clear answer, so here it is again:I just installed JCreator on my home computer, and am unable to compile any files. The error message reads: "Invalid command line. Error : Invalid path". I tried looking for the ...

jdk1.5 compile error

469 byte By cartclt88a at 2007-10-1 8:30:54
Hello,I am trying to install jdk1.5 and compile sample files, but after I installed jdk1.5 and set up classpath and path(this setting works in jdk1.4.2.06), I compile sample code Hello.java, I got the following errro,D:\Example\javac Hello.javaerror: error reading c:\j2se\bin\javac.exe; ...

Opening the command prompt?/

71 byte By damoreallya at 2007-10-1 8:31:43
How do you open up a new command prompt with a default path C:\?

illegal start of expression

2893 byte By longying23a at 2007-10-1 8:33:44
i really don't know what's wrong with the program and I was wondering if someone could tell me why I get this error?!the code file is long ,please take it easy to read it i really need help ,thanks everybody in advance......- CODE START -import java.awt.*;import java.awt.geom.*;import ...

Basic Input/Output w/ NetBeans 4.1

527 byte By Linduriona at 2007-10-1 8:34:32
I recently switched to NetBeans 4.1 from 3.6 and now I am unable to run any ofmy classes requiring basic user input. In version 3.6 input was working fine, asexpected. Now, when I run simple classes to test user input, null isautomatically entered, without pausing to prompt me for input at all. ...

Compiler Needed Urgently

839 byte By robin_drewa at 2007-10-1 8:42:18
For a project i am working on, i urgently need a compiler can take a String containing the java file definition (package + imports + class), and output a byte[] containing the compiled code.I don't believe the source to javac is available to developers (or is it?). The only other possibilities ...

help with illegal start of expression in a heap please

6914 byte By ayalexa at 2007-10-1 8:44:37
hello, i am new to java and i am trying to figure out how to make a heap, then remove the max element (from root), add a new element, and reheap. i don't know if i did it correctly, but the only error that i have now is illegal start of expression. please help if you can - thanks package ...

problem in runing a program

318 byte By Addicteda at 2007-10-1 8:59:59
Dear fellows,I m new to java programming i write the hello world in JDK and its been complied properly without any errots but its does not shoe any output on the screen i have also check the class file its been created .So any one can please guide me how can i make the output ...

problem in runing a program

318 byte By Addicteda at 2007-10-1 9:00:00
Dear fellows,I m new to java programming i write the hello world in JDK and its been complied properly without any errors but its does not show any output on the screen i have also check the class file its been created .So any one can please guide me how can i make the output ...

need help .....

683 byte By Addicteda at 2007-10-1 9:02:20
Hi fellows I m using System.out.print() for displaying in the common promt but nothing comes after the compliation.I have to do an assignment on java but due t o this i m stuck please help me out I write this programpublic class welcome1{ public static void main( String arg[] ...

Cannot build multifile project

715 byte By ScMePlza at 2007-10-1 9:12:48
Hello All, I am new to Java, and a bit lost. I've done a couple of single file programs on JBuilder, and those worked OK.Now I have a larger school project with numerous classes in numerous files. I have all the files in the same folder (the project folder). When I try to build the project, ...

class file has wrong version 49.0, should be 48.0

447 byte By chantia at 2007-10-1 9:16:17
Hi,I have a jar file(which was given by my professor) and when I use this jar file in my actual code, the following error is thrown:class file has wrong version 49.0, should be 48.0I dont have the JDK 1.5 version in my lab so I must compile only on JDK 1.4Is there any way that I can change the ...

Problem with import (CLASSPATH, JAVAPATH?)

805 byte By laboiteaproga at 2007-10-1 9:17:09
hii use suse 9.2 (linux) and java 1.5i have some environnement variableJRE_HOME=/usr/lib/jvm/java/jreJAVA_BINDIR=/usr/lib/jvm/java/binJAVA_HOME=/usr/lib/jvm/javaSDK_HOME=/usr/lib/jvm/javaJDK_HOME=/usr/lib/jvm/javaJAVA_ROOT=/usr/lib/jvm/javai use tomcatwhen i compile a java class with:import ...

about class point's display

235 byte By longying23a at 2007-10-1 9:35:30
Hello! everybody As the title my problem is which method or a class can display a pointI have found all the day ,but still haven't found the method .So I hope somebody can help me ,thanks in advance!

Class file contains wrong class

610 byte By VincentCa at 2007-10-1 9:36:36
I am trying to create an instance of my GUI as a reusable user interface and I get the following error upon compiling. What could this mean?C:\Documents and Settings\Vincent\Desktop\Vincent\Grade 12\Com Sci\Dossier\WriteRandomFile.java:19: cannot access TelephoneUIbad class file: C:\Documents ...

Ant script problem

1907 byte By jeroen81a at 2007-10-1 9:36:37
Hi people, i'm new to ant scripts but I need to make one in order to build and run my java project that consists of several class files, and the one that has to be started is Main.java. I created the following script but if I run it (by just typing 'ant' at the command prompt) no errors ...

problem with Ant

445 byte By karabasa at 2007-10-1 9:55:54
I've been trying to run ant throught the command line but I get the following error message: ANT_HOME is ser incorrectly or ant could not be located.I have set ANT_HOME to the location where i unzipped the apache-ant-1.6.2 zip file(c:\ant)I have also set the classpath to %ANT_HOME%\BIN and ...

Loading a class file from in a class file?

187 byte By MrWickeda at 2007-10-1 9:57:36
ok well i want to be able to run a class file from in a class file, so say i have both of the class's in the same directory, how could i make it have one class file run the other.

Class file contains wrong class, wait on line!!

1211 byte By phoenix_juna at 2007-10-1 9:57:54
i am sorry about trouble you guys about this issue, but i have though about it for a long time...I need to use a interface in /tmp_amd/eno/import/2/jche340/LINUX/course/ass1/util/IConstants.javaIn the file ClientStatus.java ...

Does -g impact performance

454 byte By johndidiona at 2007-10-1 10:10:10
I've always heard that compiling in debug symbols (using the -g option) degrades performance of the application, but I haven't been able to find any documented evidence of this. Has HotSpot made this untrue, was it never true to begin with, or is it just a well-kept secret? If the later, can ...

python & ant

891 byte By robert.lawless@ntlworld.coma at 2007-10-1 10:37:27
hey folks I downloaded a separate jar file (pyAntTasks.jar) to enable me to run python scripts using ant.... i have placed this jar file in the ant lib folder & also pointed the classpath towrds this jaymy build script looks as follows:<project><target name = "python"> ...

Malformed .zip archive error for rt.jar using Ant

1544 byte By tony_greena at 2007-10-1 10:38:54
I'm moving a project over from windows to a linux box.The project is built with ant. When I run it on the new box I get an error like this:build.core:[javac] Compiling 267 source files to /home/tony/work/organization/dist/classes[javac] ...

multiple implements

966 byte By sygarda at 2007-10-1 10:41:09
Hi!I am trying to make a program that listens to a serial port, and displays the incomming ascii characters in a label. I began with the SimpleRead example in javacomm and modifyed that furter. I ran into this problem:public class read_UART01 extends JFrame implements ...

Decompiling

147 byte By AFFa at 2007-10-1 10:46:11
I have an .exe file that has compiled but i want to uncompile it so i can view the code usedwhat software is good to usecheers

Encoding IP Adresses in byte format to Create InetAdress

541 byte By cangoodsa at 2007-10-1 11:15:01
Hello all,I am working on a udp client/server app for class. The app is running on a local network with no dns where the ip address starts w/ 192.168...My problem is that when i try to create an InetAddress refernce to another machine on my network java thinks that the largest number i can fit ...

how to compile?

262 byte By G0blina at 2007-10-1 11:23:57
hi,i'm new to the java platform...and semi noobish..anyways, i've finish writing my first semi big java app...now i'm wondering, how do i compile it.... and when it's compiled, how do i run it?(i'm using eclipse 3.0)thanx.

what does this mean?

3051 byte By Raf77_19a at 2007-10-1 11:25:52
invalid method declaration, return type required. I don't know what to do.this is my code.import javax.swing.*;import java.awt.*;import java.awt.event.*;public class Teacher extends JFrame implements ActionListener{public static final int WIDTH = 600;public static final int HEIGHT = 475;public ...

Good new Java Decompiler (JAD replacement)

852 byte By xtondaa at 2007-10-1 11:27:44
I know JAD is best known and most used java decompiler, but recently I have experienced has some trouble with classes compiled with JDK 1.4, it produces output with some strange things that can recompiled. It is no surprise since last version is almost four years old.So my question is, is there ...

class dependancy

817 byte By sukanta_ma at 2007-10-1 11:33:00
Hi,I have classes let say A and B. In class A i have a method called initialize().I am calling new B() inside that initialize(). The same I have a initilize() method in class B and am calling new A(). When I am trying to compile the class A , it is not showing any compilation error even if it ...

Help with Knights Tour program

8658 byte By mpo357a at 2007-10-1 11:35:06
I am trying to write a program that conducts a Knights Tour - i.e. moves a chess piece randomly around a chessboard 64 times attempting to hit each space only once. The problem is I cant figure out how to make the knight move. I have drawn the chessboard, and 64 different images where the ...

javac -g options

1020 byte By jjjefffa at 2007-10-1 11:38:57
Sorry for the cross-posting. I hastiliy posted this to the Java Programming forum and then realized there's a dedicated Compiling forum that makes a lot more sense for this question...I'm trying to get a web/Java-based management UI ready for a production run, and was investigating the ...

java not checking current directory

1428 byte By PsiRadisha at 2007-10-1 11:46:03
I'm trying to run one of my classes in command line. First time I've done this, usually use JBuilder, but I need to send command line arguments for this assignment, which is easier to do in command line.I'm using Windows XP. My class is called Fexpand. I go to the directory that the class is ...

Running java ftp task (under Win XP)

866 byte By tony_greena at 2007-10-1 11:59:28
Does anyone know the magic incantation to get the ant ftp task to work.I have sensible JAVA_HOME and ANT_HOME values. There is an ant-commons-net.jar in ANT_HOME/lib that appears to contains the ftp task. (Not in optional.jar which is what the older docs say).According to the ant docs ant scans ...

compilation warning

550 byte By mielaya at 2007-10-1 12:08:05
hi,I got a warning message when I compiled my program from command line. Note: net/neteazy/AbstractEditForm.java uses unchecked or unsafe operations.Note: Recompile with -Xlint:unchecked for details.I compiled the command "javac -Xlint:unchecked ...." and I got ...

static fields

229 byte By Akuwaa at 2007-10-1 12:09:52
Can anyone tell me how compiler compiles static or 'final static' fields? Are they holding memory for whole period time of process, or when they're dereferenced, memory will be reclaimed during the process?Thanks

Bogus "deprecated" warnings

447 byte By cowwoca at 2007-10-1 12:19:47
Hi,I wrote a class that extends HttpServerResponseWrapper and now I am getting these bogus deprecation warnings:warning: [deprecation] setStatus(int,java.lang.String) in javax.servlet.http.HttpServletResponse has been deprecatedclass CacheResponseWrapper extends HttpServletResponseWrapperThing ...

JOptionPane.showMessageDialog() help

523 byte By cliff2217a at 2007-10-1 12:20:21
I am trying to do a search on names inwhich i input into a file and then show them on a joptionpane. My problem is that I can't get it to run b/c it says that i have incompatable types. Please help if at all possible.String name, custid, num, result;int id, element;public void search(){num = ...

changing compiler

351 byte By israyona at 2007-10-1 12:30:49
Hello,When I compile java from the command prompt, it uses the javac.exe 1.4 that came together with JBuilder.I downloaded and installed jdk1.5.0_03, but still the compiler being used is 1.4i also had to change in the registry I would like to change the compiler to the 1.5How can I do that ...

Cannot complie my first java prog,

302 byte By Bzoodiea at 2007-10-1 12:37:09
Hello!I am a new coming, a beginner of Javawhen I typedc:\>j2sdk1.4.2_08\bin\javac HelloWorldApp.javathe pc show :: error: cannot read: HelloWorldApp.javaI know that I cannot compile the HelloWorldApp.java. How to fix the ...

Fatal Error: Unable to find package ...

443 byte By ryanknokea at 2007-10-1 12:38:24
Hey, im currently using using Jbuilder to build all my java classes, etc., and after uninstalling the java client and jbuilder off my computer cause of other problems, then reinstalling java and then JBuilder, i create a new project and put in my existing files, I get this error:Fatal Error: ...