32,204 Topics
| |
import java.applet.*; import java.awt.*; import java.awt.event.*; [B]public class MathApplet extends Applet implements ActionListener [/B]{ private Label lblPrompt,lblNom1,lblNom2,lblCampur; private TextField txtNom1,txtNom2; private Button btnKira; //isytiharkan button public void init() { lblPrompt=new Label("masukkan 2 nombor integer"); lblNom1=new Label("nombor Pertama:"); lblNom2=new Label("nombor kedua:"); txtNom1=new TextField("0"); txtNom2=new TextField("0"); lblCampur=new Label("Hasil campur:0"); btnKira=new Button("Kira");//objek btn … | |
Hi every1, i have trouble doing my homework. Could anyone help. the probelm is everytime when i set the degree and it prints out the last degree i entered. when i use the default constructor (withour entering any infomation) to create the UndergradStudent instance, it doesn't allow me to set … | |
Hi I want to make an applet that allows people to drag files from their desktop to the applet and it will upload through ftp. I have looked at examples of this such as rad upload and others, but when I tried to make it myself, it fails and I … | |
Hey! There has been a question on my mind for a while regarding the JRE and the class loader (or, loading classes into RAM if it's different). Java classes define variable members, methods, and subclasses. I know that when you create a new instance of a class, memory is allocated … | |
hi friends this is ram, in my system jdk is already instaled. now i want to instal netbeans what is the procedure, is that we have to give path like things plz tell me | |
Can someone help me fix this? After I compile I get ilegal start of expression for the line that says public String getBook(). I cannot see why this is not allowed. My output should be as follows: Jane Doe Long night 12.5 Long Night by Jane Doe I am supposed … | |
I have data in mysql database, i'm has succesful for connect, but how to show data in jTable. help to give me example with very detail, because i'm newbie in java progamming best regard onsir | |
Help me pls. I have some problems with method getClient(), bring only two classes. [code] package drugstore; public class DrugstoreFrame extends JFrame { Client person; ... public Client getClient(){ person.setAccount(getField(jTextField4)); person.setPassword(getField(jPasswordField2)); person.setFio(getField(jTextField5)); person.setAddress(getField(jTextField6)); person.setTelephone(getField(jTextField3)); person.setAdditionalInformation(getField(jTextField7)); return person; } private String getField(JTextField field){ return field.getText(); } public void jButton10_mouseClicked(MouseEvent e) { … | |
Hi, I am about to start learning java. I would like to ask which development tool is better. Eclipse or netbeans ? Thanks, Vishal | |
please tell me how I can execute c++ program frm java I had tried this one but it does`t work /*import java.io.*; public class exe1 { public static void main(String[] arg) { try { Runtime rt = Runtime.getRuntime(); //int s=rt.availableProcessors(); Process prcs =rt.exec("inventry.exe"); InputStreamReader isr =new InputStreamReader(prcs.getInputStream()); BufferedReader br = … | |
public class Student { private String name; public Student(String nameIn) { name = nameIn; } public String getName() { return name; } public void setName(String nameIn) { name = nameIn; } } and i get this error Exception in thread "main" java.lang.NoSuchMethodError: main | |
1.WHAT IS THEDIFFERNCE BETWEEN LOCAL INNER CLASS AND NON LOCAL INNER CLASS? [B]2.Is there any tool in java that can create reports ? 3.?What is meant by a resource leak[/B] ? | |
/bold I am trying to find some Java web applications for a project in my class. I am unable to find any. Could someone help me please? :sad: Thanks! | |
i want to find the lcm ,cant it be found without using gcd? class Gcd { int a,b; Gcd(int a,int b ) { this.b=b; this.a=a; } int gcd( int a,int b) { while(a!=b) { if(a>b) a=a-b; else b=b-a; return a; } } int lcm() { int l; if(a<b) l=(a*b)/gcd(a,b); else … | |
I have the following class and I am now supposed to add a parameter T, so that the value of Variable <T> is of type T rather than object. I am now lost with this and need some help. Not getting the generic classes. public class Variable { private Object … | |
I'm working on a program where I'm reading a file and I have to count the number of entries in the file. Each entry takes up a different number of lines, but each entry is also separated by a '#'. I'm wanting to read through the file and count the … | |
i want to find the second smallest number ib array but it is displaying second highest number int max=0,second=0; if(a[0]>a[1]) { max=a[0]; second=a[1]; } else { max=a[1]; second=a[0]; } for( i=2;i<n;i++) { if(a[i]>=max) { second=max; max=a[i]; } else if(a[i]>second) second=a[i]; } System.out.println("the second smallest nubmer is"+second); | |
hai friends my academic project is developing an editor for java. please tell me the code to compile and execute the java programme. waiting for ur reply please thanq | |
hi, every one. I want to develope an application similar to outlook express that is an e-mail client. i want to do it using Java but i don't really know how and what to use. I have been trying to find information on the internet and i came accross secure … | |
Can anyone out there please help me to implement a piece of software that is suitable to test the arithmetic level of kids. System should be able to allow more than one player at any time and produce a score for each particular user showing how many was answered rightly. | |
Hi, I am very new to java.....i know only c programming language.....even dont know c++ now i am getting training in java , i am confusing with oops concepts like polymorphism,inheritence etc. and java syntaxes all can u pls post a good link thst gives good command over oops , … | |
"ListFiles.java": Duplicate definition of class milestonemyworkspace.ListFiles, defined in H:\SDI\MileStoneMyworkspace\MileStoneMyWorkSpace\src\milestonemyworkspace\ListFiles.java and also defined in H:\SDI\MileStoneMyworkspace\MileStoneMyWorkSpace\src\milestonemyworkspace\listFiles.java. The bugs says theres a duplicate class but as you can see on the image the files look normal. I have no idea whats wrong I tried deleting the class and repasting to another class but … | |
hi i am still a beginner and i am very interested in learning this language . what is the best i can do? | |
Hi Im am so far trying to get the Jlist in my gui to display all the files in my directory H:\SDI\MileStoneMyworkspace\MileStoneMyWorkSpace\users\abimar How can I do this. If you look I madde an attempt, tried to write files to object and list objects in J list. What am I doing … | |
I have a class assignment that I am having a hard time to complete. I have started it but at ths point I am lost. Can someone help? This is what I should accomplish: 1. Create a new class called Cat that extends the PetRecord class 2. The new class … | |
Well i am doing a very simple program that is to calculate the number of occurrance of a character in a string Hello World The character H appears 1 times The character E appaers 2 times The character L appears 3 times The character L appears 3 times The character … | |
does anyone have an implementation of a slotted aloha scheme or know how i can implement it? i have data that i need to read in from a file about each packet that will be transmitted across the channel. any ideas? thanks. | |
pleas help me i want acode that convert infex to prefix in java language heeeeeelp. | |
ListFile class takes care of writing the files to Jlist Basically there is a Jlist in my GUI and I want it to display the files stored in my user folder. But for some reason it doesnt work the Jlist say that there is Null file. [code = java] package … | |
I was executing a simple core java application using JDK1.5 I wrote code and complied using javac it gave some errors that i fixed and at last it got complied successfully But when i tried to exeute it using java it gave me an error message Error in thread main.NoSuchMethodFound … |
The End.