32,204 Topics

Member Avatar for
Member Avatar for 65piano

First of all, I'm new to GUI so I may have made some terrible mistakes.. right, so I have a two dimensional array of buttons and I need to identify which button in the array is clicked, hovered over, and hovered off. For now I just want my program to …

Member Avatar for JamesCherrill
0
197
Member Avatar for joankim

Hi there guys. I am soon halfway through AP computer science, where we learn Java. Right, now, I'm doing some extra credit programs, both for fun, and to learn this stuff better. However, I got stuck on a few of them, and I really need some advise. I have already …

Member Avatar for zeroliken
0
143
Member Avatar for jamojo

Hello Everyone, I am using apache POI 3.7. I am trying to replace the value of a table column in a word document (docx). However, what I have done is it keeps appending the value of the current value in the document. But if a table column value is null, …

Member Avatar for jamojo
0
3K
Member Avatar for Jenna1994

i am trying to make this shape using java ********************** ********************** ***************** *************** ************ *************** ****************** i have TRIED at the bottom as u can see but i am unable to get this shape i am confused [code]public class courseforuni { public static void main (String [] args) { int …

Member Avatar for zeroliken
0
107
Member Avatar for manou324

Hello! I'm trying to make a class,but an error comes up.I have also an another class named Ticket.Thanks for your help! [CODE]import java.util.*; public class TicketPool{ ArrayList box= new ArrayList(); public void AddTickets () { box .add(new Ticket ()); } public void DisplayTickets (){ for (int i=0;i<box.size();i++){ System.out.println(box.get(i)); } } …

Member Avatar for manou324
0
205
Member Avatar for libathos

I am using a JFreeChart from this link [ICODE]http://www.java2s.com/Code/Java/Chart/JFreeChartCategoryStepChartDemo.htm[/ICODE] the format of the datasetUtilities.createCategoryDataset is (new String[]{..,..,},new String[]{..,..,},data).Is there any way that i can pass an already filled arrays for countries and years? [CODE] public Chart(String tablenm,final double[][] data,String[] countries,String[] years) { super(); final CategoryDataset dataset = DatasetUtilities.createCategoryDataset( countries,years, data …

Member Avatar for libathos
0
196
Member Avatar for Dmiller071

Hi all, I have a slight problem with a java applet of mine. I play a video game that tracks realm and world ranks and I'm making this applet to put on my site to display current standings. My main problem is currently in the testing of this applet. Once …

Member Avatar for Dmiller071
0
270
Member Avatar for Dregron

Hey first time posting about code so please say if you need more information than what i give you... I'm having trouble with a timer, am trying to wait 2 secs then add 5 to Defender.Bullets but they are a delay on this and it bugs out if i keep …

Member Avatar for Dregron
0
226
Member Avatar for Hussam Alahmadi

in this assignment make the program read 10 integers and store them in an array. Then, pass this array to a method that finds the largest integer in the array, and counts its occurrences. Your method should return a string of the form largestNumber

Member Avatar for stultuske
0
140
Member Avatar for 03hasnam

[CODE]import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.event.*; import java.text.*; import java.lang.*; import java.util.*; import java.io.*; public class PaymentNewGUI extends JFrame{ private JButton tenP, twentyP, fiftyP, onePound, twoPound, payButton; JTextField ticketID; Label lEntranceTime; Label lPaymentTime; Label lTimeDifference; Label lDue; Label lInserted; Label lMessage = new Label("Enter Your Ticket Number"); Container …

Member Avatar for JamesCherrill
0
1K
Member Avatar for jerrohnny

Hi Guys, Am one of those changing careers. I am retraining on an IT Conversion course at the moment and has just started java. Being a conversion program, it is running really fast and I am working really hard to catch up and fully understand, am gonna need all the …

Member Avatar for JamesCherrill
0
113
Member Avatar for dennysimon

usualy I run java app ( I create by my self) by click it's jar file. How to run it via click an icon on desktop ( how to link between icon and the jar file thank you denny

Member Avatar for dennysimon
0
581
Member Avatar for karthik.datt

The withoutcomment.txt file contains : [general] "PC", 0x0, 32, RW, reg , 1, "Program Counter (R15)"; "LR", 0x11, 32, RW, reg , 18, "Link Register (R14)"; "SP", 0x10, 32, RW, reg , 17, "Stack Pointer (R13)"; But i am able to print only first line but its not going to …

Member Avatar for stultuske
0
170
Member Avatar for ibthevivin

So basically I'm stuck at the do-while statement. Should I use a do while? or a for loop? This program is supposed to test my ability to use loops. [CODE]/*Create an application that reads an integer value and prints the sum of all even integers between 2 * and the …

Member Avatar for stultuske
0
236
Member Avatar for Traicey

Guys I have been trying to figure this out until this very moment The problem is I need a piece of code that will not allow the user to enter any negative number in the text box This how it should work, if the user trries to enter this "-" …

Member Avatar for stultuske
0
164
Member Avatar for matrixcool

Hello, I have a file and this it how it looks like: 6 {a, b, c, d, e, f} 1 1 1 0 0 0 0 1 1 0 0 0 0 0 1 0 0 0 0 0 1 1 0 0 0 1 1 1 1 0 1 …

Member Avatar for zeroliken
0
2K
Member Avatar for janvi.dodia

Hi everyone.. i m developing an application to backup files\directories to a server.. i initially developed it in RMI but then to make it possible to run over Internet i made some modifications and used sockets.. I have designed few packets for sending login details, file information to be backed-up, …

Member Avatar for zeroliken
0
1K
Member Avatar for matrixcool

Hello, I have a file and this how it looks like: 6 {a, b, c, d, e, f} 1 1 1 0 0 0 0 1 1 0 0 0 0 0 1 0 0 0 0 0 1 1 0 0 0 1 1 1 1 0 1 1 …

Member Avatar for matrixcool
0
245
Member Avatar for 03hasnam

[CODE]/*********************Pay Button Listener***************************************/ public class payListener implements ActionListener{ public void actionPerformed(ActionEvent e) { replace(); Ticket getNewPayTime = new Ticket(); getNewPayTime.loadTicket(ticketIDNumber); paymentTime = Ticket.paymentTime; //getting correct ticket pyament time, correction performed by replace method. long timeDifference = paymentTime - entranceTime; SimpleDateFormat sdf1 = new SimpleDateFormat("MMM dd,yyyy HH:mm"); Date paymentdate = new …

Member Avatar for NormR1
0
142
Member Avatar for moonL!ght

hi im having this error i dont now where is the mistake can you halpe me? this is the exception: java.lang.NullPointerException at shape.shape.<init>(shape.java:14) at shape.rectangle.<init>(rectangle.java:17) at shape.listOfSHAPES.init(listOfSHAPES.java:73) at sun.applet.AppletPanel.run(AppletPanel.java:424) at java.lang.Thread.run(Thread.java:619) these are part of my code were it show the error list of shapes class:[CODE] else if(shape.charAt(0)=='R'||shape.charAt(0)=='r') { int …

Member Avatar for stultuske
0
207
Member Avatar for Artmann

Hi I've been working with Java for a while now but there's one basic thing I still don't understand. Java got 4 Access Modifiers [LIST] [*]Default [*]Public [*]Private [*]Protected [/LIST] I know the difference between them, the thing is I don't now why you should use different Modifiers. Wouldn't it …

Member Avatar for Ezzaral
0
150
Member Avatar for ziadkassam

Hi, please, I want the shortest path algorithm using arrays (Data structure) and the path passing through all the points once and return back to the initial point. ex: 0-1-4-2-3-5-0 (path cost=10) 0-3-2-5-4-1-0 (path cost=15) so 0-1-4-2-3-5-0 is the correct answer.

Member Avatar for ziadkassam
0
78
Member Avatar for thejoker011

Hey guys....Namastey!! Am here for your suggestions. I am right now working on a software project which needs to communicate with an custom ECU(Engine/Electronic Control Unit) of a car via a USB-TO-RS232 cable. Before moving ahead i want to be sure, [B][COLOR="Red"]do you think Java is appropriate for such kind …

Member Avatar for thejoker011
0
381
Member Avatar for gourav1

hey! i m reading java. and at one place i have read Audio interface in which play(), loop() functions are defined,but interface is something in which there can't be any method defined. so this must be abstract not interface.so please tell this problem, y we are calling this as interface. …

Member Avatar for thines01
0
266
Member Avatar for Mr.BunyRabit

i got an example form roseindia on how to send an email. Now it works perfectly like this, and i can send mail to my email adress with that code (thats just a part of it) [CODE]String host = "192.168.1.14"; String from = "Admin@Admin.com"; String to = "myEmailadress.com";[/CODE] but the …

Member Avatar for Mr.BunyRabit
0
429
Member Avatar for horizondesai

Hi everyone. I'm using jwt 2.5.2 and new to it. I want to create a table (rows & columns) in it. Is this possible with jwt 2.5.2 ? Is there any data type like 'TableItem' ? What is Also, what is character for tab-space in it ? '\t' doesn't work …

Member Avatar for horizondesai
0
161
Member Avatar for gourav1

i m not getting how to play a mp3 file using applet? i m using AudioClip A = getAudioClip(x); where x is --> URL x=C:'Users'gourav'java_pr; its just a try! i donot know how to use this. it is showing error. tell me how to use audioclip interface?

Member Avatar for stultuske
0
98
Member Avatar for Jenna1994

hi im jenna and i have been learning java i have to write a program that does the stuff listed below i have tried multiple times but i am not getting it right:'( i dont understand what to do please help me :( i have to hand it in to …

Member Avatar for stultuske
0
204
Member Avatar for gsingh2011

I came across a program a program called Enounce MySpeed which allowed me to watch videos (my school lectures) at a faster rate. I was able to watch 60 minute lectures in 25 minutes, so this software was extremely valuable to me. However, this software is shareware, which is dumb, …

Member Avatar for ~s.o.s~
0
115
Member Avatar for Jenna1994

The End.