32,204 Topics
| |
The Application should be able to add an entry , view an entry and delete and entry.. All other functions are working properly but my applica tion cannot delete.. Please assit where i shuld place my delete method import com.jjpeople.addressbook.action.actionresult.ShowAddressActionResult; import com.jjpeople.addressbook.actionargument.ShowAddressActionArgument; import com.jjpeople.addressbook.actionargument.DeleteAddressActionArgument; import com.jjpeople.addressbook.businessdelegate.AddressBookDelegate; import com.jjpeople.addressbook.businessdelegate.AddressBookDelegateException; import com.jjpeople.addressbook.businessdelegate.AddressBookDelegateImpl; … | |
What I'm doing is making a game and I need to do this for my items: - Have an "Item" Class - Have other superclasses such as:Weapon,Armor,Food - Read XML file with items on it. - Create appropriate Item classes with the correct extended class. - Fill the fields with … | |
| Hi everyone, I'm trying to write a basic program to find the root of an equation. I just tried compiling it for the first time and I get the following error: RootFinder.java:6: <identifier> expected public static double searchValue(double x0, x1, a) { ^ RootFinder.java:6: <identifier> expected public static double searchValue(double … |
When "ENTER" button in value class clicked the show class wil be run. but nothing happend import java.applet.*; import java.awt.*; import java.awt.event.*; import javax.swing.*; /*<applet code ="value" width=200 height=200> </applet>*/ public class value extends Applet { private JLabel lab1; private JButton btn1; public void init () { // Construct the … | |
Hi coders, I create a BSTree but i don't know if it is right. I only want to create a bstree with Strings, nothing else. my code: import java.util.Scanner; class Node { private Node left; private String number; private Node right; public Node() { left = null; number = "0"; … | |
I am facing some problems in a project regarding to byte fetching from a file and storing. Problem in java bytes is they are number, instead of char. In file i have seen a byte is like a char... Also how to make bytes unsigned , because signed bytes creates … | |
Hey all, I have a JApplet that runs in browser and I can't get it to create a new JFrame popup when a button is clicked. It works fine in my IDE (Eclipse) but not when I upload it. Here's the code for the JFrame I'm trying to create: import … | |
I'm looking for a java tutorial site that will teach java and also give some exercises. Any other sites would be helpful too. | |
The application should have one method that populates the multidimensional array with data and another method that shows the contents of the multi dimensional array. Both methods should be triggered from the main method. Assist because am been notified that the code below is not correct public class ArrayExample { … | |
public class ForLoop { public static void main(String[] args) { String writtenStuff = "Hello i am bucky bucky"; int otherNum = 0; int length = writtenStuff.length(); int i; for (i = 0; i < length; i++){ if (writtenStuff.charAt(i) == 'b') continue; } }//end method }//end class Here is my code, … | |
Hi ive been given some question as part of a homework assignment, just to clarify i dont want the answers to the questions just advice as to where to look for resources. The Socket programming model and how that model works in Java, explaining clearly how Sockets support a simple … | |
I havent done java in a while and not sure what to do with the void methods please can someone help me out thanks whole thing is in a zip file as well done in bluej as there is a long list of code here. /** * class Player * … | |
public static void main(String[] args) { String searchMe = "Look for a substring in me"; String substring = "sub"; boolean foundIt = false; int max = searchMe.length() - substring.length(); test: for (int i = 0; i <= max; i++) { int n = substring.length() int j = i; int k … | |
Ffirst of all, i have just achieved to code a program that counts the chosen letters. ( For example, i wanted it to count how many 'p's exist in the string. ) Now, for example i want to code a console application that extracts only the ones that are not … | |
public class ForLoop { public static void main(String[] args){ String writtenStuff = "someone was here!" + "here i am!"; int numP = 0; int length = yazi.length(); for (int i = 0; i < length; i++){ if (yazi.charAt(i) != 's') continue; ++numP; }//for end System.out.println("the total number of the letters … | |
This program is one part of the GUI part for my reminder program. I would like to update the JTable which shows all the task and will refresh every 2 second. I have questions... (1)the SwingWorker never executes( I put println in the code but it shows nothing ) How … | |
the assignment to create 4 classes to make message server i made the code but i have an errors | |
Hi, I am running Java 1.6.0_31 on my machine and would like to have "Nimbus" set as the default look-and-feel for my Java applications. I have followed the instructions obtained from the Oracle java website i.e. by creating a text file named **swing.properties** with the following line of code **swing.defaultlaf=com.sun.java.swing.plaf.nimbus.NimbusLookAndFeel** … | |
I get this error. /*array dimension missing new ImageIcon [] = getClass().getResource(name[0]),*/ ^ and I dunno what's missing. and not sure if anything else is wrong because for now there are 4 erros for name[0],name[1],name[3],name[4] import java.awt.*; import java.awt.event.*; import javax.swing.*; import java.awt.Container; import java.io.IOException; import java.io.*; import java.awt.BorderLayout; import … | |
I was trying to use java's native Properties class to edit my ".properties" file and save them, but then I was put off by the fact that in order to do that I had to "store" the properties file by re-writing it back to disk, which simply erased all other … | |
I have started a database application just like an address book, however I would like to have the user to upload a picture that will show when the user click save. Any idea? Thanks alot | |
How to code in Java (with Java Media Framework): When the player reaches a certain time playing a video clip (for example, reaching 3.124 minutes in reproduction time), it generates an event? | |
Hey When I try to interpret thru PHP, a Java web service that returns a boolean type, this error (more like a warning) pops up: Notice: Object of class stdClass could not be converted to int in C:\testing\page.php on line 29 It seems this is something PHP related. How can … | |
im a begginer with the gui code , i tried to add an image by making an imageicon then adding it to a Jlabel nd finally adding it to my frame all this while trying to put a button in front of the label but i cant seem to get … | |
public class Main{ public static void main(String[] args){ User u1 = new User("My Super Ex-Girlfriend", 5734); User u2 = new User ("Morad", 5734); User u3 = new User ("Fatma", 5734); Network n = new Network("Telecom international", 5734); Message m = new Message ("My Super Ex-Girlfriend", "Morad", "My heart in pain", … | |
i have a function that is supposed to check a string against a set of types, stored as a hash set in the class o. however the function only works if there is one word. if the string conmtains more than 2 words, my program crashes with NullPointerException. public static … | |
How to provide auto size re-ajustment in java design i.e when vb.net form are expanded then it automatically expand the button and textfield appropiatly like nothing changed... while in java every thing messes up... Any Suggestions. | |
import javax.swing.JOptionPane; import java.text.DecimalFormat; public class payrate { public static void main(String[] args) { String str; String name; double horasT; // horas trabajadas double rate; // rate por hora double salarioB; // el salario bruto name = JOptionPane.showInputDialog ("Entre le nombre del empleado: "); do { str = JOptionPane.showInputDialog("Entre las … | |
Hello, I would like to get some help please. I am a newbie in Java and i am stuck. Actually I wrote a code in which i want to draw a circle and then move that circle downwards like free fall. I can deal with the coordinates but i don't … | |
Hey Guys, Could someone guide me o show examples of how i can hit a url and find whether its dead or alive, well simply i want to monitor couple of sites incase they go down so if the site is returning me holding page or any other error i … |
The End.