32,199 Topics

Member Avatar for
Member Avatar for kukuruku

Hi ,I am learning Java ,and I have problem ,when I call this method form main and chose 1 it is printing enter name and enter priority without letting me enter the data how can I fixed that Thanks [CODE] public void makeChoise(){ switch(display()) { case 1:System.out.print("Enter First and Last …

Member Avatar for Akill10
0
253
Member Avatar for curbster

Hi all, I'm almost done with a problem for a java class I'm taking. The chapter I'm studying is on inheritance and I think I understand it ok. The parent class will compile fine, but when the child class tries to compile I get an error saying it cannot find …

Member Avatar for curbster
0
463
Member Avatar for Nathan Campos

Hello, I'm building a program that gets the value of a [b]TextField[/b], concatenate with some other [b]Strings[/b] and then display them on a [b]TextBox[/b] when the [b]ScreenCommand[/b] is clicked, the problem is that it's calling a [b]NullPointerException[/b]. My code is like this(of course it has a lot more stuff): [code=java]/* …

Member Avatar for jon.kiparsky
0
199
Member Avatar for Beschatten

Hey, so I'll post what I have, the code is pretty self explanatory. I have a hunch that there are more efficient ways to code than using these long and repetitive if statements, so if you guys could help me in that direction that would be great. I also am …

Member Avatar for jon.kiparsky
0
118
Member Avatar for cozmo87

I'm reading the filenames/directories of all the files within a folder into an array of Files. The filesnames are all of the type: Name1, Name2, Name3, Name4, Name5, Name6, Name7, Name8, Name9, Name10, Name11, Name12, Name13 The above shows the correct order in which the files [B]should[/B] be ordered. However, …

Member Avatar for BestJewSinceJC
0
204
Member Avatar for nickliutw

Here is the requirements: create a class include first name, last name, and monthly salary variables. Create a set and get method for each instance variable. What is the set method for(I read the book several times)? I don't quite get how to use it. How to create a set …

Member Avatar for peter_budo
0
135
Member Avatar for BUBBLE231

Write a complete Java program that uses a loop that computes the expression m + m+1 + m+2 + ......... n-2 + n-1 + n. m and n are to be integers input from the user and should be checked for validity against the conditions 1 <= m <= n. …

0
38
Member Avatar for Sidd_

hi 2 all How to get todaz date in java and store in a string thanx in advance

Member Avatar for anuj_sharma
0
104
Member Avatar for xdrnpcx

Well i am working on a drink dispenser machine and got stuck on array part, this program includes selecting a drink, show price, show changes and a option whether to purchase drink again They are being placed on various method like public void A() select drink... public void B() calculate …

Member Avatar for xdrnpcx
0
159
Member Avatar for Abdel_eid

hello All, i am working on a small project to show people address through there names , for example the user will enter the name and it will show him the address of the entered name.. but the big issue here is that i want to googlize it which means …

Member Avatar for Abdel_eid
0
95
Member Avatar for alemojarro

I am new to java, and have this assignment do when I have to count consonants and vowels among other thigs , and I already wrote a program that works. However, I feel that there is still room for improvement specifically in the vowel and consonant counts. Could you help …

Member Avatar for alemojarro
0
198
Member Avatar for ztini

I'm having some fundamental issues with some basic abstraction. Here is the super class: [CODE] public abstract class Tile extends JLabel implements MouseListener { public Tile() { setIcon(new ImageIcon(getClass().getResource("images/blank.gif"))); } @Override public void mousePressed(MouseEvent e) { System.out.println("clicked"); switch(e.getModifiers()) { case InputEvent.BUTTON1_MASK: leftClick(); break; case InputEvent.BUTTON2_MASK: rightClick(); break; } } public …

Member Avatar for ztini
0
186
Member Avatar for ankurmawanda

am trying to connect a jsp page to a postgress database i have created a jdbcconnects.java file and compiled it with jsp_api.jar from my apache..../lib directory i have placed the class file in root/WEB-INF/classes folder the code of my class file is [CODE] import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; public …

Member Avatar for ankurmawanda
0
178
Member Avatar for Jaydenn

Heres my situation: I have a server that people connect to. The server runs off the source files on a virtual private server. The files are always being updated when I edit them because they sync with dropbox and the vps. Is it bad to do this, and would it …

Member Avatar for ztini
-1
83
Member Avatar for insanely_sane

Hey guys. I'm brushing up on my GUI programming in Java and I am using the Ready to program IDE(by holtsoft). So the title tells it all really. I have tried and failed, but I need to see if there is a way to get the typewriter effect (as in, …

Member Avatar for ztini
0
163
Member Avatar for Neversleepin

Hi, here i just try to delete the content in text file between S and e letter. but i don't know to write the ReplaceAll() methode after this [CODE]String[] paras = Pattern.compile("^(S)(.*)(e)$").split(inputText);[/CODE] How could i use ReplaceAll() here? Thank you

Member Avatar for Neversleepin
0
135
Member Avatar for jemz

hello please help me how can i get the height of the tree?I really don't have idea how to get this can you help me please thank you in advance hoping for your positive response...here is my code [CODE] private Node root; public boolean isEmpty() { return root==null; } public …

Member Avatar for jemz
0
186
Member Avatar for sciprog1

Hello, I have a JFrame, inside which is a JPanel, in which I am drawing lines in the paintComponent() function at an interval of 1 second. The screen always freezes. How can I change the program below such that I can see the lines being drawn after every second? Thank …

Member Avatar for Ezzaral
0
364
Member Avatar for initialise

Hi All, I am writing a client server program that has quite a few GUI's in it. Basically, everything is working except for the problem I'm encountering. Well, obviously :P I am not currently running my server program in order to simulate what would happen to the client if the …

0
125
Member Avatar for sirlink99

This is a very simple timer and I cant seem to get it to work I have tried this () runs but does nothing: [code] // The "Timer" class. import java.applet.*; import java.awt.*; import javax.swing.*; import java.awt.event.*; public class Timer extends Applet implements ActionListener { // Place instance variables here …

Member Avatar for javanoob101
0
880
Member Avatar for Magekiller

Hello all, Im trying to figure out how to get the for loop for (int i = 1; i <= (11 - 2 * line); i++) { System.out.print("*"); ... to show the method listed at the bottom. I've been able to get the rest of it, just not this part. …

Member Avatar for jon.kiparsky
0
87
Member Avatar for stupidenator

Hey everyvody... I have this crazy idea for a program... I want to be able to load an image (most likely a .jpg) into a java program and then I want the program to print out the binary code that makes up the image and save it to a .txt …

Member Avatar for Urchin1111
0
468
Member Avatar for saisakthi

Hello friends, I am an android developer. I developing an application with uses the music files. For that I need javax.sound jar package. But I dont find any link to download the package. Can anybody send me a link to download javax.sound jar?

0
74
Member Avatar for newbie14

Dear All, I have one main class calling another class but I keep getting this error " SMSClient cannot be resolved to a type". Before this I tried on other pc it was ok. Below is part of the codes. What could have been wrong? [CODE]public class callSMSClient{ public static …

Member Avatar for newbie14
0
14K
Member Avatar for brynFlew

Hello, does anyone have an example of radio buttons working with a java bean. It would help out allot. Thank you

Member Avatar for brynFlew
0
276
Member Avatar for freaky_sxyvs

Hi, I am vee and I am trying to create a Natural Language search engine based on LSI. I am stuck up and I would be really glad if I could use some help. I have a two-dimensional array which is full of numbers. I want to transfer the contents …

Member Avatar for masijade
0
502
Member Avatar for Shanti C

Hello all, I have successfully deploy my jsp project into webserver.It is running fine. But my problem is , my project contains some .java/.class files where i have written classes and methods. If i want to change this .java file and re-upload it to web server, it is not get …

Member Avatar for Shanti C
0
181
Member Avatar for stephy1

I am having one Authentication frame in swings. i have created another frame where authentication page on successful completion of verification should go. How to link or connect these two things? I am using Swings with Netbeans. Is there any UserInterface controls in netbeans or i have to code inside …

0
70
Member Avatar for queenking

Good day to all.. I am a beginner in java. I have a problem, I don't know how to convert string into an array which reads 60 characters.. supposedly, this is my code.. [CODE]import java.io.*; import java.util.*; public class Strinpunct{ public static void main (String [] args) throws IOException { …

Member Avatar for masijade
0
223
Member Avatar for Gsterminator

So my homework assigment was to create a new method in the class section called, public void deleteStudentsWithName(String)...So what it does is reads a files, converts it into an array, and then it asks the user which name you want to delete. My program is very messy(in my opinion), but …

Member Avatar for Gsterminator
0
252

The End.