32,199 Topics
| |
Hello, I need help!!! Very new to programming. I need a program that will display a menu with the letters C,E,F,L and X for exit and allow the user to select a letter from the menu. If the user selects X,print an appropriate message and end the program. If the … | |
Hi everyone! I have a homework problem and I can't seem to get it to work. We're supposed to make a snowman melt when you click on it with the mouse, but my snowman refuses to melt. I know it's a problem with the mousePressed method in the MeltingSnowman class … | |
I am trying to build an application through which i can send messages from server to client. My application is similar to the windows messenger application of windows operating systems /*(to see windows messenger service go to control panel -> administrative tools -> computer management -> click services & applications … | |
Hi all I was wondering if someone can let me know of a quick and easy way of interacting with a Javascript control on a web page. "<a href="#p189191" name="option66" onclick="selectPollOption(66);" class="vote">Vote</a>" That's the control I would like to activate, I was thinking I could use a regular expression to … | |
I have an applet that is not initializing: [code=JAVA] import javax.swing.*; public class WordSearchApplet extends JApplet { public WordSearchApplet (int width, int height) { } public void init () { new WordSearchApplet (700, 800); } } [/code] Here is the error I get. [quote] load: WordSearchApplet can't be instantiated. java.lang.InstantiationException: … | |
Hello, I'm creating a subclass from an already defined class. Let's say I have a class called Student and it has a default constructor. Now I want to create a child class of Student, but when I create it, it seems that it's taking the constructor instead of the actual … | |
I have a project for school and I cant figure out what to do. I need all the help I can get. Its due tonight and I am stumped. I have spent 7hrs on it today already and Im stumped 100%. Here is the assignment. We use Netbeans to write. … | |
I wrote the code for the following 2 combo boxes which display a drop-down list of dorm buildings and meal plans for a college student. The code works, and both boxes are displayed. I have completed what I have to do, but want to find a way to get the … | |
hello i try to use SLF4J for logging. i try something like this: [CODE] import org.slf4j.Logger; import org.slf4j.LoggerFactory; import util.HibernateUtil; public class Main { public static void main(String[] args) { Toolbox tool = new Toolbox(); tool.helloWorld(); } } class Toolbox { Logger logger = LoggerFactory.getLogger(this.getClass().getName()); public void helloWorld() { logger.debug("Temperature … | |
i am in a first semester programming class and this probably might seem like a dumb questino to everyone here but i have been working on this for along time and cant seem to come up with anything. i am stuck on 2 programs. the first is to ask for … | |
How can I override a method in a base class without using the @Override sign? For example the class Human below overrides some methods in the class Mammal. Do print the output correctly without @ signs in objects. Convert them correctly before outputting. [code]import java.util.*; public abstract class Human extends … | |
I created a combo box for the selection of a dorm.... I need to create another combo box for the selection of a meal plan... Should I write that in another class, or can I add it to this class? I need to display the total of the costs of … | |
Hello, I am trying to write a program that allows the user to enter a letter and using seven different methods to print out the letters. This display should look like this CCCCCCCCCC CCCCCCCCCC CCCCCCCCCC CCC CCC CCC CCCCCCCCCC CCCCCCCCCC CCCCCCCCCC The method printBlock should accept a character and two … | |
Hi, I had posted this question before and I did appreciate the response I got. However I still need some little help as: [B]1.In the addMovieGoers method check that every member of the collection is a human and that they are old enough to watch the movie, if not throw … | |
Hi , I lke to write the angram game. But I dont know how to sort the words in random Ex:the words gonna be lke this ..J H R E I O M C I want to let the user to type the meaningful words to choose among from that … | |
Hi there, I have an assignment due in a couple of days and I need some help. I don't have time to read a Java books. Plus, my teacher is useless as he can't explain anything...and the TAs are worst. My error is in line 145 (scroll down) saying "illegal … | |
Hi there...I can get the input from a user...however I need to add them. I'm thinking I need a loop to add them, and carry the extra if the person adds them. Keep in mind, the max size is 20, and I have no added the error checking in there. … | |
Hi, I am having some trouble with arrays. I have an array of 5 elements. The values of the array are integers. I want to validate the input using an if statement. (the numbers must be between 10 and 100). I then want to compare the user input to the … | |
Hello, I am trying to get this code to work. I am getting an error code on line 38, that I don't understand why. Can anyone help me out. the error code that I am getting is identifier expected. Thanks, countrygirl1970 [code] // Displaying multiple strings import javax.swing.*; // To … | |
hi we have a programming assignment which computes the volume of a barrel. I don't have a compiler yet and java is not yet recognized by my computer yet because I haven't downloaded any JDK yet because I don't know which one to download...Here's my code so far...Please just review … | |
I have got two arrays. One for initializing and another for displaying. The display array always shows nothing if the initializing array has not been called. The problem now though is that if I want to insert something in a certain slot in the array nothing happens and I dont … | |
I am just learning Java. I am trying to do a GUI to calculate road trip data. My program compiles, and a window opens, but only the top title line shows. Nothing shows in the center or south areas. What do I need to change? Here is my file. [code=syntax] … | |
any1 know s anything about cr8ting mobile game "go" need ur help | |
i am new to java, i am writing this program so where when the user inputs RGB values the resultant colour should be displayed on a frame. (note that you cann't use the [B]color class in java[/B]) 1.) i have successfully completed coding for where the user inputs the RGB … | |
Has anyone tried and succeeded in Inter JVM method calls within a single machine. What I mean is I have two separate applications running on the same machine using two JVMs. Can they communicate and if so what are the related packages and classes. antaryami | |
Hi all, I have an assignment to hand in tomorrow for programming and would appreciate any help that is given. I have done a couple of years programming with VB but java is like on a completely level compared to it. Ok, so basically I have to program an application … | |
Please solve mysome Queries. In java, Why we use enable Events() method[B]?[/B] Which technique/concept can be use to implement multiple inheritances in java[B]?[/B] How can a GUI component handle its own events[B]? [/B] My email: [email]ahsan.mit@gmail.com[/email] | |
Hi How can i get a recursive function like this to work: It should find the sum, then print the sum out inside the function. [CODE] public static int myMethod(int counter) { int sum = 0; if(counter == 0) return 0; else { sum = sum + myMethod(counter-1); System.out.println("Sum is … | |
Hello, I want to use ajax upload I m using [COLOR="Red"]"commons-fileupload.jar"[/COLOR] for uploading file... and below code is used to call servlet through ajax. Actually I am new in ajax so I can't understand what happens while I use multipart request. My javascript is [CODE]<script language="javascript"> function getXMLObject() //XML OBJECT … |
The End.