108 Posted Topics

Member Avatar for scobi

Actually your question has nothing specific to RadioButton it will be the same for any component. As peter_budo mentionned, you have probably a lot of different layouts in that application. Which one gives you the problem ? Which RadioButton is not a the good place ? Post the code for …

Member Avatar for scobi
0
222
Member Avatar for unknown12

These 2 lines do not make sense [code] double a = keyboard.nextDouble(); a = getBalance(); [/code] Input a user value from the console and storing it into variable a Erasing the just read value from the user calling getBalance() getBalance() in any case should be called from a Check object …

Member Avatar for pbl
0
138
Member Avatar for sirlink99
Member Avatar for borchu

ouf really complicated for nothing assuming you want values <= finalSize [code] int[] newArray = new int[finalSize]; Random ran = new Random(); for(int i = 0; i < newArray.length(); ++i) newArray[i] = ran.nextInt(finalSize) + 1; [/code]

Member Avatar for borchu
0
196
Member Avatar for plasticfood

and what does your isPrime(int) method looks like ? and i++ is a waste of time is useless :) i += 2 will do it no need to test all even numbers

Member Avatar for plasticfood
0
118
Member Avatar for privatestatic

By the way, to respect universal practive by C/C++/Java/Fortran programmers for ( int i = 0; i == s3.length() -1; i++) should be for ( int i = 0; i < s3.length(); i++)

Member Avatar for pbl
0
108
Member Avatar for RedDevilMalaya
Member Avatar for adams161

Java does not have/needs preprocessor directives as C/C++ has no macro, no #define so no preprocessor that's it

Member Avatar for adams161
0
230
Member Avatar for deb081900

Has nothing to do with the fact that your buttons are in a ButtonGroup or not [code] private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) { Object o = evt.getSource(); if(o == button1) { ... } else if(o == button2) { ... [/code]

Member Avatar for JamesCherrill
0
647
Member Avatar for SaranyaKrishnan

What Protege tool are you talking about ? Google protege tool returned to me a lot of links most of them in the biomedical field and one in Software Engineering but that one is a kind of JFrame designer without any API to get/set property

Member Avatar for pbl
0
71
Member Avatar for sirlink99

Your question does not really make sense [i]I have a file that produces a random number in a folder called number.[/i] How can a file produces random number ? A file is data storage on a media. It does not generate anything. A program does. [i]I have a file that …

Member Avatar for pbl
0
89
Member Avatar for rayden150

A Client class whith as instance variables: - String account - double balance - double[] transaction or ArrayList<Double> transaction - double creditLimit should do plus obviously a public void main(String[] args) method to test the whole thing

Member Avatar for pbl
0
105
Member Avatar for javap

is 524 n int or a Strng ? If it is a String [code] String str = "524"; for(int i = 0; i < str.length(); ++i) System.out.printl(str.charAt(i)); [/code]

Member Avatar for JKP()
0
148
Member Avatar for sharathg.satya

could you post some of the "ideas" you have tried and tell us what was wrong with them ?

Member Avatar for sharathg.satya
0
174
Member Avatar for mani_1991
Member Avatar for newcoder310

You can extend a class from a package but you can't extend the package itself and you will have to show your directory structure and how you do your import statements

Member Avatar for JKP()
0
98
Member Avatar for daudiam

Actually not 100% true. Static variables can be used if declared [i]final]/i] which is good for the serialVersionUID. I guess it is just because it would be to difficult (or time consuming at run time) to implement because the Java Virtual Machine has restrictions on calling private members from outside …

Member Avatar for ~s.o.s~
0
164
Member Avatar for gedas

Don't see why you don't use the JList for data processing. After all a JList is just an ArrayList with GUI features

Member Avatar for quuba
0
231
Member Avatar for billy leung

You will eventually have to read them. You can make a checksum on the files content. If the checksums are different they are obviously not equals. If the cheksums are the same then no choice than comparing them line per line.

Member Avatar for billy leung
0
178
Member Avatar for in._.cloud

Probably a .jar that is defined in your NetBeans IDE external .jar but whose directory is not in your PATH environment variable

Member Avatar for pbl
0
41
Member Avatar for دموعي

And what is your problem ? One thing for sure [code] for(i=0;i<5;i++) { if(e.getSource()==ADD) [/code] no need to check 5 times that ADD is the JComponent that generated the Event

Member Avatar for دموعي
0
101
Member Avatar for khurram.1987

Did you download MySQL.jar file ? If so is this .jar in your PATH variable or in the External Jar folder of your IDE if you use an IDE ?

Member Avatar for khurram.1987
0
161
Member Avatar for plasticfood

Depends in which context you are If you are generatiing a .exe or a .jar should be the name of the file where these will be written If you are generating JavaDoc the .html file ... there are about 6 of these

Member Avatar for plasticfood
0
70
Member Avatar for jlovesfishiee

Design your own GUI by hand. Netbeans generate hardly understandable code by human being. What will you do at a job interview if they ask you to design a very very simple GUI using only Notepad ? Stay away from GUI generators.

Member Avatar for jlovesfishiee
0
91
Member Avatar for jon.kiparsky

come on it is not that complicated to make it recursive in a single loop [code] static long getDirSize(File dir) { if (dir.isFile()) return dir.length(); File[] subFiles = dir.listFiles(); long size = 0; for (File file : subFiles) { if (file.isFile()) size += file.length(); else size += getDirSize(file); } return …

Member Avatar for jon.kiparsky
0
337
Member Avatar for bangor_boy

You can just overload a method You will have first to extends the class then you can overload the method [code] class MyClass extends theClassThatContainsOpenRead { // now you can overload public boolean openRead() throws.... { // your code here // if filename and sc are private you will have …

Member Avatar for pbl
0
111
Member Avatar for usiyalla

Don't now of ones already make but with a JEditorPane and an HyperlinkListener shouldn't be complicated to write one [code] public class WebBrowser extends JPanel implements ActionListener, HyperlinkListener { private JTextField url; private JButton button; private JEditorPane editorPane; public WebBrowser() { super(new BorderLayout()); url = new JTextField(30); url.setText("http://"); button = …

Member Avatar for usiyalla
0
127
Member Avatar for mag12203

Please use code tags and indent your code correctly it is a nightmare to read And why check for isLetter ? just if charAt(i) == charAt(j) should do

Member Avatar for mag12203
0
175
Member Avatar for mini programmer

Please post your code using the code tags We lost the "pedagogic" approach of this site if viewers have to dowload your code

Member Avatar for mini programmer
0
160
Member Avatar for sijothomas
Member Avatar for pbl
0
85
Member Avatar for JAVA4ME

Not really an easy task You can scan the directory structure until you find what you want but this solution is not really elegant.

Member Avatar for pbl
0
102
Member Avatar for churva_churva
Re: GUI

"I recommend using an IDE which compiles as you write, you can find errors much quicker" This is not the good way to really learn (my opinion)

Member Avatar for Akill10
0
281
Member Avatar for Ritesht93

Syntax is: java -jar jarfile.jar arguments so assuming the .jar file is Maintenance.jar the command should be java -jar Maintenance.jar optional parameter java -jar Maintenance.jar Attendance

Member Avatar for Ritesht93
0
205
Member Avatar for ITjulz

Spent 2 years at Microcell programming this on cellular phone. I'll be glad to help you with any problem you will encounter.

Member Avatar for pbl
0
287
Member Avatar for AaronLLF
Member Avatar for raghavp

You obviously have a recursive call Most probably a constructor calling back itself but without seing your code not easy to diagnose the problem

Member Avatar for pbl
0
260
Member Avatar for arshi9464

Probably because you want all users on the computer to have JRE accessible and select the users with JDK access Don't see any other reason

Member Avatar for hertze_bogdan
0
107
Member Avatar for daudiam

Windows In the Hotspot implementation, the way that Thread.yield() works has changed between Java 5 and Java 6. In Java 5, Thread.yield() calls the Windows API call Sleep(0). This has the special effect of clearing the current thread's quantum and putting it to the end of the queue for its …

Member Avatar for ~s.o.s~
0
694
Member Avatar for arshi9464

Each instruction are 1 byte in lenght but might be followed by bytes of data iload 1 goto 38 does not produce in all format but the one of your JRE [url]http://en.wikipedia.org/wiki/Java_bytecode[/url]

Member Avatar for ishaanarora
0
114
Member Avatar for kdmuk10
Member Avatar for kdmuk10
0
174
Member Avatar for Akill10

If you followed these instructions [url]http://download.oracle.com/javase/tutorial/deployment/jar/basicsindex.html[/url] it should work

Member Avatar for Akill10
0
127
Member Avatar for Akill10

You might think that you are pressing multiple keys at the same time but a few milliseconds between each of themm will make a difference Anyhow, even if you manage to click 2 keys at exactly the same time, the hardware will sent 2 distinct interrupts and queue (randomly) the …

Member Avatar for Akill10
0
286
Member Avatar for num90
Member Avatar for pbl
0
82
Member Avatar for jonicse037

I am making my PhD thesis at MIT Can you please send me a thesis ?

Member Avatar for pbl
0
50
Member Avatar for arshi9464

RAM is allocated in the heap as required The important point is that as Java does not allow arithmetic operations on pointers and validates array bounds you cannot access data outside the JVM. So you cannot pick and poke around.

Member Avatar for pbl
0
47
Member Avatar for ajst

Keep GroupLayout for GUI builder but if you still want to use them the JLabel should not be added to the JPanel (using the JPanel add method) as you do but to the horizontalGroup and verticalGroup you created [url]http://download.oracle.com/javase/6/docs/api/javax/swing/GroupLayout.html[/url]

Member Avatar for ajst
0
1K
Member Avatar for ksbp

This is the Java forum not the javascript forum Even if the names are similar, they are not related at all

Member Avatar for pbl
0
90
Member Avatar for rajkumar_
Member Avatar for gladius33

The % returns the modulo (reminder) of first number divided by second number so 5 % 2 is 1 and 6 % 3 is 0 so if(num1 % num2 == 0) it means that num1 is an excat multiple od num2

Member Avatar for pbl
0
144
Member Avatar for coding101

Window -- Preference ---- General ------- Appearance --------- Colors and Fonts ----------- Basic

Member Avatar for pbl
0
38

The End.