32,199 Topics
| |
Hey everyone, I'm currently writing a simple text based MUD in Java for learning purposes. Currently I'm in the process of coding a Login class that prompts the user to enter a user name and password in order to access the account. Right now the problem lies in opening a … | |
hi, i m just wanna open/explore/view inside of any txt or doc file from folder by using JFileChooser... here i made the code, pls tell me what need to add to open the files.. [CODE] import java.io.File; import javax.swing.JFileChooser; public class OpenFile { public static void main(String args[]) { JFileChooser … | |
Hi, I need to create a time delay before I call a method. [CODE]public void brewDrink(CoffeeMachine coffeemachine) { try { coffeemachine.displayDrinkBrewing(); Thread.sleep(7000); setDrinkReady(coffeemachine); } catch (InterruptedException ex) { } }[/CODE] This doesn't work, the method isn't called. Any help or pointers are welcome! | |
I want to remove the JOB node with JOBNAME "One" from the following file: <SETTINGS> <SYSTEM> <VERSION>3.1<VERSION> </SYSTEM> <JOB> <JOBNAME>One</JOBNAME> </JOB> <JOB> <JOBNAME>Two</JOBNAME> </JOB> </SETTING> The code that is supposed to remove it looks like this: [CODE]try { DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); DocumentBuilder docBuilder = factory.newDocumentBuilder(); Document doc = docBuilder.parse(new … | |
Hi i have the next task to solve. [I] A bank holds different types of accounts for its customers: – Deposit accounts – Loan accounts – Mortgage accounts Customers could be individuals or companies. All accounts have customer, balance and interest rate (monthly based). Deposit accounts are allowed to deposit … | |
how we can send binary sms to any mobile particularly nokia mobile from pc using smpp... | |
I am trying to write a java program for a SNMP,DNS using UPD datagram. I am trying to think of how to start. Anyone has any suggestions? Please advise | |
Hi I am trying to genarate report in java. my basic requirement is like: 1. i have to print sales invoice in .txt format. 2. In application, user will select sales invoice no in drop down list. after clicking print button, user can show his invoice . 3. invoice contain … | |
Can anyone help me to implement binary search tree with addition ? | |
Hello, Nice post man...but do you have nay link for the java monkey engine that is used for creating games? | |
Hi! i need to insert a new element in an existing xml document. for example, [code=xml] <details> <person> <name>Anu</name> <email>abc@yahoo.com</email> </person> <person> <name>thara</name> <email>xyz@gmail.com</email> </person> </details> [/code] In this document if i want to insert another element using Xpath, say,<publisher> in <book> node, how to insert it. I'm using DOM … | |
So I have a web audio stream that I would like to capture. What I want this program to do is grab the stream, record it and write it to a file (mp3, wav..whatver codec that is easy) and create one hour intervals of the audio stream. So every hour … | |
Hello all, I have created an RSS object and I would now like to parse out the descriptions of the children. My knowledge of RSS is extremely limited so pardon me if I am incorrect in explaining what I need. For example, I am connecting to [url]http://rss.cnn.com/rss/cnn_topstories.rss[/url] and I would … | |
I am a adult returning student in Java and would really benefit from having someone work with me on exercises to further my understanding of the material. Anyone interested in helping would be greatly appreciated. | |
I was wondering if someone can help me with how to convert my code so that it converts the cents to dollars and also round to the nearest cent: [CODE]public class Subscription { private int price; private int length; public Subscription(int p, int n) { price = p; length = … | |
I'm currently taking Java I and I have to write a program that reads 5 integers and determines and prints the largest and smallest numbers without using an array. I have to only use the if statements. I can't figure out how to make the if statement apply to 5 … | |
hello please help me on this i make a simple program that inputs the first name and family name and age, and this will display to the table ...can you help me how to delete the save data on my JTable the one that i inputed ...thanks in advance hoping … | |
hello can you help me please... i have a button print and i dont know how to make the code that will print all my data in my database....please help me how to make this print code ..hoping for your positive responds. | |
I have written my program to prompt the user to enter an integers and then print if the number is odd or even. It says build successful, but will not prompt for the information to be entered and print the data. I use Netbeans with the JDK bundle. Please help. … | |
Hello all! I thought I was finally getting good at this "Java" thing, and then someone suggests to me that I use a singleton and factory class. I'd never heard of these before so I set off googling it. Now, I get the gist of singleton and factory classes, but … | |
I am using Ubuntu 9.04. I want to shutdown my PC using Java, when some Event is called. Please suggest what could be done. | |
kindly please tell me how to connect from java to ms access, sql,oracle and so etc . with example | |
Hello to all my fellow IT people! I have two questions! I would like to start learning how to program! Is Java a good beginners language to start with and if it is not what is a good language? My second question is if Java is a good language then … | |
public double getThirdSide() If the triangle is not valid, this should return 0. Otherwise it should return the length of the third side of the triangle. i cant figure out how to put this into coding any help thanks [CODE]public class Triangle { //PART 1 // a triangle is defined … | |
Hi all, I'm new to java applets. This is basically my first bigger applet. It works 100% fine when I run it in the applet viewer. As soon I start it in a web browser it stops working half way through. The code below is a short version of my … | |
So I am working on storing inorder traversal indices associated with every node in a BST (So if I add BAC, then the inorder index of A = 0, B = 1, C =2). The thing is that whenever you add a new node to a BST, you must recompute … | |
/** * Simple math application using a scanner input * @version 1.00 2010/1/26 */ import java.util.*; import java.text.*; import java.io.*; public class mathopr { public static void main(String[] args) { double num1,answer1,answer2,answer3=0; String myname; String reply; char replyChar=; Scanner input = new Scanner(System.in); DecimalFormat df= new DecimalFormat("00.00"); while (replyChar=='y'){ System.out.println("Please … | |
hi, i m facing a small prob in GUI, need to save my output to a particular folder. below this code showing the square of any integer in TextField named: "resultField". i've a button "save" that need to save the result from that TextField, suppose in my "c:\Repository " folder … | |
Is there a simple way to find and store the depth of every node in a BST using recursion? I can't seem to figure out a straightforward way of doing so. | |
I'm fairley new to programming in general being a fresh IT graduate. Some software I am developing needs to be able to compress a folder in to a .zip file and later extract it while maintaining its file structure. I am able to do this but extracting the file takes … |
The End.