Search Results

Showing results 1 to 17 of 17
Search took 0.01 seconds.
Search: Posts Made By: darkagn ; Forum: Java and child forums
Forum: Java 15 Days Ago
Replies: 3
Views: 203
Posted By darkagn
The main method in a java application has the following signature:

public static void main(String[] args)

If you are a beginner I would suggest starting with something a bit simpler than a...
Forum: Java 25 Days Ago
Replies: 7
Views: 303
Posted By darkagn
You type java Hi, there is no need to specify the ".class" to run your program. Also, you will need a main method in that class to run the program.
Forum: Java 33 Days Ago
Replies: 15
Views: 640
Posted By darkagn
Hi alreem,

We can only help you if you show that you have made some sort of an attempt. Do you have an algorithm or some code that you have tried? We may be able to point you in the right...
Forum: Java Oct 20th, 2009
Replies: 6
Views: 480
Posted By darkagn
Hi easyb and welcome to DaniWeb :)

You don't need to use Math.pow at all. Math.pow is used to find the power of a number. I wish that banks would pay interest exponentially but unfortunately... ;)...
Forum: Java Oct 10th, 2009
Replies: 2
Views: 381
Posted By darkagn
String number = Float.toString(number);

I think what you are trying to do is convert the number n to a string yes?

What I would do is this:

String number = new Float(n).toString();


Here...
Forum: Java Oct 10th, 2009
Replies: 2
Views: 358
Posted By darkagn
Hi ankiwalia and welcome to Daniweb :)

Your SQL syntax is incorrect. Instead of this:

String query="select username and password from Registeredusers";

Try this:

String query="select...
Forum: Java Mar 20th, 2009
Replies: 9
Views: 404
Posted By darkagn
In order to tell what parameters you need to pass to the method, you can look at the method signature. In your Pizza class, let's look at how the setSize method is described:

public void setSize...
Forum: Java Mar 11th, 2009
Replies: 3
Views: 562
Posted By darkagn
About 50% of my job is in documentation and technical support. There are many help authoring tools out there and in general you get what you pay for. http://hat-matrix.com/ might be able to help you...
Forum: Java Nov 13th, 2008
Replies: 4
Views: 425
Posted By darkagn
Should zipCode belong to the Individual class or the IndividualArray class? I think it is a value relating to the Individual, not the list of Individuals.
Forum: Java Jun 24th, 2008
Replies: 8
Views: 3,180
Posted By darkagn
You need to call Graphics2D.setStroke(Stroke) method before drawing a line. You will need to create a Stroke first - use the BasicStroke class for now. Also, don't forget to reset the stroke after...
Forum: Java Jan 21st, 2008
Replies: 3
Views: 3,390
Posted By darkagn
Hi Akeem Amure and welcome to Daniweb :)

A couple of things before we start - please don't shout (by using all capitals) and there is no need to ask for help as soon as possible as we always try...
Forum: Java Jan 13th, 2008
Replies: 1
Views: 1,180
Posted By darkagn
Rather than implementing the ActionListener in your class, it is probably better to add an ActionListener to your menu item. You can do this by

// Exit menu item
exitItem = new JMenuItem("Exit");...
Forum: Java Dec 18th, 2007
Replies: 13
Solved: isFixReg() ???
Views: 1,507
Posted By darkagn
dReg1 in the above code is an Accumulator, a register that is used to keep track of the result of the calculations. If you think about how a calculator works, you enter a number, press the operator,...
Forum: Java Dec 15th, 2007
Replies: 13
Solved: isFixReg() ???
Views: 1,507
Posted By darkagn
It looks to me like it is a flag to tell whether something has been inputted or not. If it hasn't, isFixReg is set to true, and pressing a number (for example) starts a new String. Otherwise,...
Forum: Java Dec 11th, 2007
Replies: 9
Views: 1,594
Posted By darkagn
Ok I don't want to give it away, but the line String "type"; is not how you initialise a String. And it is in the wrong method.

You have moved the line Triangle T = new Triangle(); from where it...
Forum: Java Dec 1st, 2007
Replies: 9
Views: 1,260
Posted By darkagn
Hi piers,

The problem is that you posted a huge chunk of code that any of your fellow students could copy easily by searching for "scanner" in google. I think that is what the person is implying...
Forum: Java Oct 7th, 2007
Replies: 2
Views: 8,757
Posted By darkagn
Hi Libran,

To help debug your code, try adding some println statements to gain a better understanding of what is going on. Please see my comments below.



import java.util.*;
import...
Showing results 1 to 17 of 17

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC