32,199 Topics
| |
I have tried to figure this out and am having major problems with math pow. Any help would be great... This project deals with reading input from the user, storing the input into variables and displaying those variables. This program is an introductory project into the basic data types of … | |
I'm trying to figure out how to transfer several methods in a cash register into one void method. Here is my code. /** * A cash register totals up sales and computes change due. */ public class CashRegister { private double purchase; private double payment; /** * Constructs a cash … | |
| import javax.swing.*; import java.awt.*; import java.awt.event.*; import java.sql.*; class NewUser //extends Variable implements ActionListener { JInternalFrame ifrm; JLabel lbleid,lblena,lbleadd,lbletp,lbleage,lbluse,lblpas,lblcat; JTextField txteid,txtuse,txtena,txteadd,txtetp,txteage,txtpas; JButton btnadd,btndelete,btnclear,btnsearch,btnupdate; JComboBox cmbcat ; public JInternalFrame display() { JInternalFrame ifrm=new JInternalFrame("User Process",true,true,false,false); // ifrm.getContentPane().setLayout(null); ifrm.setSize(600,600); ifrm.setLocation(0,0); ifrm.setResizable(false); ifrm.setDefaultCloseOperation(ifrm.DISPOSE_ON_CLOSE); ifrm.setVisible(true); JPanel p; p=new JPanel(); p.setLayout(null); //pic =new JLabel(new ImageIcon("Employee.jpg")); … |
I have a complex UI with little screen real estate, so I'm trying to allow users to manage contents of a combo box using a right-click context menu. But I'm having trouble getting the combo box's drop down list to appear at the same time as the pop-up menu. I've … | |
How to write a program to calculate incoming and outgoing packets at each system. what are the different files which are used to calculate Ip and Mac address? R there any files which are used to draw real tie graph? | |
Oracle Certified Professional Java Programmer was formerly known as the Sun Certified Java Programmer certification. Does anyone know if the switch to Oracle has changed anything significantly, such as the questions that will be on the test? Or is it the same cert with a new name? The reason I … | |
I am fresher in software engineering seeking job. But i want to know in which designation can i able to be placed. I am some what good in programming (java,c,c++). When i registered in any companies they ask me about job code. And also i am undergoing course in web … | |
Hey, I was thinking of trying to write my own custom swing component. I was thinking of a simple text based component that would act like an open book. Text would be displayed on the left side/page of the component until there is no space left and then the rest … | |
hello, I had a fckeditor at my php page, i want to put some data in fck editor when user click a button. How can i do that using javascript. Please help | |
I am trying to make an Inventory GUI application using MySQL and NetBeans. So far, i was able to do add,delete,search, and save using Java Desktop Application. I now have to add a SEARCH button, a notification for the quantity if it is less than 10 and a USERNAME and … | |
Can i create a Ms access database through java code? Can i place Ms access Database inside my project and can i manipulate them? | |
Hi all, I have written a basic program with 3 option using a switch statement, the 2nd option being a reverse string code using charAt() when you select option 2 and press enter it then switchs to case 2: which then asks for the string you wish to reverse, is … | |
Hey! I'm taking my first CS class and new to all this... i'm using eclipse. i need to prompt the user to enter their FULL name ie. John Smith. i cannot ask the user to enter their 1st and last name separately. i then have to print/display the name in … | |
i can trap Number only but i cant trap letter inputs. how to do that? please? example. Enter a letter: 5 "INVALID INPUT! PLEASE ENTER A NUMBER!" please guys?! | |
Hello, i want to know what's the use of new keyword while Initializaing the array in JAVA.How it's helping in java whether same like new in c++ or malloc in c | |
Hello my friends I have a txt file with the follow layout [QUOTE] error1 255 error2 34 error5 111 error3 23 [/QUOTE] and what i'm trying to achieve is, from this text file plot a trend chart with the errors and respective quantity! this is the code that i'm using.... … | |
I've been programming in Java using Java SE, but I want to move on to Java EE. Is this a good idea? I used to think I had to pay to download the Java EE SDK, but that's not the case. So, basically, I'm a bit confused about what Java … | |
[CODE] int a,b; double temp; int sortTheNumbers = sentenceList.size() - 1; for (a = 0; a < sortTheNumbers; ++a) { for (b = 0; b < sortTheNumbers; ++b) if(score[b] < score[b + 1]) { temp = score[b]; score[b] = score[b + 1]; score[b + 1] = temp; } } [/CODE] … | |
Hello, I'm trying to write a program for matrix multiplication I keep getting an error.... Please help [code] class Matrix { private int numRows, numColumns; private double x[][]; public Matrix(int m, int n){ numRows = m; numColumns = n; x = new double[numRows][numColumns]; for(int i = 0; i < numRows; … | |
import java.awt.*; import java.awt.event.*; import javax.swing.*; public class MenuDemo extends JApplet { // Text fields for Number 1, Number 2, and Result private JTextField jtfNum1, jtfNum2, jtfResult; // Buttons "Add", "Subtract", "Multiply" and "Divide" private JButton jbtAdd, jbtSub, jbtMul, jbtDiv; // Menu items "Add", "Subtract", "Multiply", "Divide" and "Close" private … | |
hi..I am really new in Java software development..I am trying to make sure that the JXTable will refresh or update the data after the save button is clicked which means that the JXTable will display the lastest data that retrieved from the database..as what I had googled through the methods … | |
When I try to run what I have so far in my program, I get an error when I enter in the date as 11/11/2010 that states "Exception in thread "main" java.util.InputMismatchException". Why am I getting this and how do I fix it? Also, I have some comments in the … | |
I can't believe I'm asking this, but this assignment I was given is proving very difficult. I was asked to find the ECLOSE function of a given Epsilon non-deterministic finite automata. All it is is the BFS tree of a graph from a given point, provided that the vertices are … | |
So even though this is a simple project, I found a lack of good code on the web under this topic for multi lined strings. I thought I would share it with everyone. Hope it helps you! Prints file foward first, then in reverse (and yes there are many different … | |
Hello, I'm really new to doing Java only been doing it about 2 month so really a novice. I'm currently attempting to make my first app that is not a school project. I want to embed the current time in my application that is pulled from the local system. It … | |
i need to make a tree canopy in the shape of a pyramid drawn using nested loops the tree should look like this [url]http://cs.nmu.edu/~rappleto/Classes/CS120/Assignments/beach-assignment.html[/url] i have the trunk but i cant figure out the tree top to save my life. any ideas on where to start? thank you to all … | |
Hi, I'm trying to make my own sokoban game in java. Sokoban is a top down 2D puzzle game where you move around a level trying to push boxes to the goal area in the least possible moves. I'm already pretty stuck at an early stage. My first objective it … | |
i just need a method that will draw me a flower but it says illegal start of expression error on line 36. what does that mean and how do i fix it? import java.applet.Applet; import java.awt.*; public class ProjectTwo extends Applet { public void paint(Graphics g) { ///background g.setColor(Color.blue); g.fillRect(0,0,1366,384); … | |
I'm just starting out in java, and I am totally stumped on this assignment. I have to make a program where the user selects a single character and then a file. The program is then supposed to check each character in the file, and output how many times that character … | |
i cant sort it descending? why? please help me!! [code] import java.io.*; import java.util.Arrays; import java.util.Collections; public class alpha { public static void main(String args[]) throws IOException { BufferedReader br = new BufferedReader (new InputStreamReader(System.in)); int num = 0,c,x,a = 0,d,e,letter1,f; String input; System.out.println("\t[WELCOME]"); for (d = 0;d<=2;d++) { System.out.print("How … |
The End.