32,199 Topics
| |
I have attached 4 classes which I have created for the following assignment, as well as a test program which tests the other four classes. The only thing that I am having a problem with is reporting the amount of the fine in the ParkingTicket class, as well as determining … | |
Hello, I am trying to write a simple program that takes input from the fields I have created for the following UI and writes them to a command prompt. Can someone help me with the next step.... getting the input entered and writing it to the prompt? I would also … | |
i am trying to accept a 3 by 4 integer matrix from the user and an unable to do so.here is my code. [code] void accept()throws IOException { int i,j; InputStreamReader instream = new InputStreamReader(System.in); BufferedReader stdin = new BufferedReader(instream); System.out.println("\nEnter the coefficients and the constants for the 3 equations … | |
hello, when compiling this method, i get a "missing return statement error" because there is no return statement after the while loop and before the method closes. i understand that there needs to be one there, i'm just not sure what the value should be. i have commented out the … | |
If someone could help me out here I would really appreciate it... I have to get this code running for my programming class and i keep getting same symbol error here is the code: [code] public class fourseventeen { public void main(String[] args) { int j = 0; int sum … | |
Ok, here is the problem. I have to ask a group of people for donations and get the total average and so on. The only problem I have is trying to get the lowest donation from the inputted numbers. I can't seem to get the actual lowest number. It just … | |
Some of the time, we have to run/execute the SQL scripts using command prompt or the sql browser, but i were to replace these actions with just a single click of button, i need to create a functionality with java whereby users can perform these actions with an interface. But … | |
Hi, Everything else in this code works properly but the keyTyped method is not working properly. I have been working on this for sometime. Any help would be appreciated. Also, any advice on getting my southPanel to appear when I start the application? It appears but only after I expand … | |
So, I got this idea that I could make a simple game in Java, with animated GIFs for the running animations, but I have a problem, although Java will display the animation on a JLabel when made into an Icon, but I don't know how to, and can't seem to … | |
Hey guys, I wanna download a file to a certain directory on the computer. I have code that downloads to the same place where it's launched but I want it to download the files do another directory. (This isnt my code I found it on a tutorial) Here is the … | |
i need help with converting celsius to fahrenheit and vice versa in my program. for example, if someone would input 0C for the first temperature and 32F for the second temperature, i need to convert one of these temperatures so that my equals method can recognize that they are equal … | |
Hi, can someone please help me, I am new to Java and I am getting a NullPointerException error and cant figure out why Here is the code class TestBirthday { public static void main(String[]args) { int num; System.out.println("Enter number of people to test"); num = Console.readInt(); Birthday2 Experiment = new … | |
Hey all I have to use an external library itext-1.4.5.jar in a program helloWorld.java.It is located in /usr/share/java First I had compiled as $javac -classpath /usr/share/java/itext-1.4.5.jar HelloWorld.java Then I had created a manifest file manifest.mf as Manifest-Version: 1.0 Created-By: PreetiC Main-Class: HelloWorld Class-Path: /usr/share/java/itext-1.4.5.jar But on doing $ jar cmf … | |
Hello, this is my first post here and I noticed that other people have been struggling with this assignment too. It is the mortgage calculator program for UOP PRG420. So I am sure you all are probably about sick of this by now, but I need help. The book is … | |
Compared to javascript's power, i think xslt is so weak. i prefer parsing xml document to whatever html representation using javascript and i cant see any use of using xslt for that matter. What do you think? | |
[ICODE]import java.util.Scanner; public class lab3 { public static void main(String[]args) { int floor; int rooms; int occupied; int totalRooms; int totalOccupied; int totalVacant; double occupancyRate; Scanner keyboard=new Scanner(System.in); System.out.println("Please enter the number of floors in the hotel: "); floor=keyboard.nextInt(); while(floor<1) { System.out.println("The number of floors cannot less than 1, please … | |
Hey guys, I want to make a program copy output from a Command Prompt window, any idea how I can accomplish this? In my program I want to have a console type menu so the user can watch what is going on. Thanks PO | |
Hi, I want to show running time in java Please write java code for me. thanks in advance. | |
Hi Guys, I am trying to get a program I made to auto-start on my computer, but I don't wanna use the "startup" folder. How do these other programs automatically start? I went to my "msconfig" and then to the startup tab and found references to "HKLM\SOFTWARE\Microsoft\Windows\CurrentVer..." and I looked … | |
[code] package Sorting; import javax.swing.JOptionPane; public class Sorting2 { public static int s[] = new int[100]; public static void main(String[] args) { String ask = ""; for (int i = 0; i< 5;i++){ ask = JOptionPane.showInputDialog("Enter: "); s[i] = Integer.parseInt(ask); System.out.println(s[i]); } for (int x = s.length-1; x>= 0; x--) … | |
Hi, How to add image to Jwindow. Here is my code: import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.text.*; import java.io.*; class Project4 extends JWindow { Container container; JTextField jt; JButton jb; public Project4(String st, final Image image) { container = getContentPane(); container.setLayout(new BorderLayout()); //JTextArea jtp = new JTextArea(st,10,10); //container.add(sp); … | |
Hi, I am developing an application to generated Jasper Report. I am using Netbeans 6.5, jasperReport 3.1.3. I am developing it using Visual web JSF. My JSP file is [CODE] D:/Programs/Java/JasperReports/EmployeeReport/web/Page1.jsp [/CODE] My report file is stored in [CODE] D:/Programs/Java/JasperReports/EmployeeReport/web/WEB-INF/reports/employeeReport.jrxml [/CODE] I have used following statement to specify my source … | |
| hello. i have a problem running my very first applet (im just converting my previous application to applet). i tried to follow the instructions i found in the manuals, both the one given by my prof and the ones i found in the web, but unfortunately my program wont work. … |
Hello, I need to write a program that holds a multiple product inventory. Using an array to store the items. The output should display the product info, one at a time. In addition, I have to include the Total Value of the entire inventory. My only problem is, the total … | |
Hi all, I would have a question. I know that I should (or must) respect the encapsulation rule (as one of the main three Java features) but what about if I have some "Data Structure"? I mean something like "struct" in C/C++. So if my class contains only data (not … | |
Hi, [B] I am trying to write a simple java application that detects motion. The application gets its images from a webcam with the address:[/B] [url]http://studiocam1.disp.duke.edu/jpg/image.jpg[/url] (you can watch the live video feed at: [url]http://studiocam1.disp.duke.edu/view/index.shtml[/url]) [B]My current plan is: (I have little experience, so it may be wrong)[/B] 1. I … | |
Hello folks, I m trying to simulate the RSA algorithm. This is some of my code: [ICODE] System.out.println((int)Math.pow(6, 5) % 119); System.out.println((int)Math.pow(41, 77) % 119); [/ICODE] The first results in 41 while the second results in -9 when the expected shud be 6. Whats wrong? | |
Dear Members I am having a problem in Java and I am pasting the code and the error message please tell me where is the problem and aslo tell me any directory that can guide me about frequent error messages and their solutions. here is the code. import javax.swing.*; import … | |
hello everyone, im trying to make a theatre program and im at a dead end so im hoping for some help please. if someone can help see my problem clearer or post some sample code it will be much apperciated. the problem is i need to create a Seat class … |
The End.