35,618 Topics
![]() | |
hi i need the answer of :- write any 3 java programs, but their is no java programs in the computer | |
Java swing component jtabbedpane is opaque even after jtabbedpane.setBackground(new Color(0,0,0,0)); or jtabbedpane.setBackgroundAt(index,new Color(0,0,0,0)); | |
trying for the longest while to get this program to run at least properly, havent finished entering all of the codes as, just testing each part of the statement before i add in the rest of the codes the program is not working properly dont know where I have gone … | |
Every time I try to compile this code I get the same error but it doesnt seem to make any sense. This is the code: public class Software Development { public static void main(String[]args) { System.out.println("Hello World"); System.out.println("2name"); System.out.println("name: \n"+name); System.out.println("\"name:\""+name); } } And this is the error: Software Development.java:1: … | |
I am currently working on a program that asks a student to answer 5 simple maths questions after each question it will state whether the answer is right or not. which it will out put a grade and grade average percentage. Currently I'm stuck on the if statement where it … | |
package deviation; import java.util.Scanner; public class Deviation { public static void main(String[] args) { Scanner input = new Scanner(System.in); System.out.println("Enter n: "); int n = input.nextInt(); System.out.println("Enter " + n + " numbers: "); double[] x = new double[n]; int i; for (i = 0; i<n; i++) { x[i] = … | |
Sorry for the misleading question guys, I know how to generate two random numbers but I want to use them in One JOptionPane input Dialogbox so the user can add the two numbers. Below is my code of what I have done so far I know it's not a lot … | |
hi all i am doing a programing and got stuck on two condition. here is the code that I have done so far. it is as far as i reach. for(int i=1; i<=3; i++){ System.out.println("please enter the employee id number"); emp_idnum = input.nextInt(); System.out.println("please enter the employee first name"); empfirst_name … | |
Hello, Thank you for your time! I am trying to understand the Quick Sort algorithm. I have some questions about the partition method. I found the following implementation online: import java.util.Scanner; public class QuickSorts { public static int partition(int a[], int left, int right, int size) { int pivot = … | |
At my work we have an internal webite that only uses Java 6. 7 and up will crash the site locally. I am aware that it really needs to be update for many reason. Does any one know of a way to launch IE to use an older version of … | |
I have a JTable that has four columns. In the second column I have assigned a JComboBox to be the cell editor of my column.The problem that I encountered is that I cannot handle the combobox the way I want. **What I want is that after a user select an … | |
Hello I am new to Java & I am trying to find ways(in built Java objects/ways) to parse HTML. Can you suggest some objects in the Java Standard Library? I have extended the object HTMLEditorKit.ParserCallback but when parsing a web pages' source code it literally takes 2 minutes or more! … | |
![]() | here is my code and i have tokenized the data in my .txt file.I want to insert them into a database. import java.io.BufferedReader; import java.io.FileReader; import java.io.IOException; import java.util.StringTokenizer; public class test1 { public static void main(String[] args) { BufferedReader br = null; try { String sCurrentLine; br = new … |
<html><head></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">import java.text.DecimalFormat; import java.util.Scanner; public class BookBillSystem { public static void main(String[] args) { //create the Scanner instance for taking input from console Scanner scanner = new Scanner(System.in); //take input customer name System.out.print("Customer Name: "); String customerName = scanner.nextLine(); //take input noOfBooks purchased System.out.print("No of books … | |
When I try to type in a set user to add to the friends list, it shows up blank via [[]]. I know I'm missing something or it's the way I set up the input, but I can't figure it out. Main Driver import java.util.*; public class main { public … | |
I want to ask >>what is the use of (string args[])??? and how can I use system.exit >>without intially import the package (java.lang) ? thanks ^^ import javax.swing.JoptionPane; public welcome1 { public static void main (stirng args[]){ JoptionPane.showMessageDialoge(null,"welcome to java"); system.exit(0); } } | |
![]() | i am using eclipse to write code that allows me to take a text file containing data (in my case it looks something like this :20 30 40 50 etc).i want to write the code in java and i am using eclipse as my IDE.i need the database to be … |
Here my code. package formsign; import java.awt.*; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.ItemEvent; import java.awt.event.ItemListener; import javax.swing.*; public class textF extends JFrame{ private JTextField fname; private JTextField lname; private JPasswordField pass; private JTextField country; private JTextField zip; private JTextField month; private JTextField day; private JTextField year; private JTextField phone; private … | |
Hello all, I am trying to take input from user using scanner. The problem is, when the loop starts, it skips taking input for the first iteration. Here is the code: import java.util.Scanner; public class TrigTriangles{ public static void main(String[] args){ int N; double a,b,c; double A,B,C; Scanner s = … | |
Hi i have an application created in grails.. class Route { Integer prlNo String name String address String address2 String address3 String month Integer week Integer day Integer position String van String period Integer rang static mapping={ sort:["rang","day","position"] } and i have a controller that look for same van to … | |
- Hi there. - I'm learning Distributed System and having an assignment of building a simple Game server using RESTful webservise. I'll use Java to build this server. And i need some help. - The game server provides the following services: + Register an account using for all game provided … | |
Hi, I have been searching out a lot of things to sove my problem but none of the solutions I found worked in my case :'( Here is what I am trying to do: 1. When the screen is off, my BroadCastReceiver detects it. 2. Once screen_off is detected, acquire … | |
Hello All, I am working on a project for class and I have everything work except for one little thing. I can compile there is no issues with running the program. However, when get prints the information I get a null as the value for the Mobile OS. I do … | |
I'm in AP Computer Science A* I was doing the following problem: int i = 1; while ( i < 10 ) { int j = 10; while ( j > i ) j--; i += j; } System.out.print(i); The output is 16, but can someone please explain why it … | |
what input statement is used in a float..` import java.util.Scanner; public class Program1 { public static void main(String[] args) { float Fahrenheit, celsius; Scanner input = new Scanner(System.in); System.out.print("Enter temperatue in Celsius"); celsius = input.nextDouble();<---- this line is giving a run time error. Fahrenheit= ((9 * celsius)/5 +32 ); System.out.println(celsius … | |
Hi I am a senior at high school. The school is making us create a product to present and I want to create a Java computer program for my product and present that. I want to make something cool and something that'll make you go "wow". I've narrowed my category … | |
somebody can help me... | |
[This article](http://lifehacker.com/the-top-programming-languages-ranked-by-job-demand-po-1601752302) will give you at least one good reason... | |
I am developing a java application that uses a jtabe to allow the user to capture data. This data would be written to a text file later. The application is working fine. Good. However, I wanted to add a button such that when a user click this button, the application … | |
Hi i am new to java and i need help to write program for this problem Updating inventory A national chain is making room for new inventory, so it is selling existing inventory at discounted prices. All products in the store are on sale, but the markdown percentage varies depending … |
The End.