32,199 Topics
| |
I need a java code for downloading files from the internet ..For example I want to download doc,pdf files from the internet means i have to do it through my code ..So can anyone help me | |
Hello and thanks in advance for your time. Trying to learn how to throw App Exceptions. Is there any way to get this exception from properties so I can pass it to a JOptionPane? Model Resources UserException=Subscription failed. \ Please try another email address. ProfileException=Must Select a Profile \ UnenrollException=Unsubscription … | |
Okay so I'm supposed to write a report describing the classes and interfaces I will use to implement a popular online photo management system called flickr ([url]http://www.flickr.com/[/url]). I don't need to implement any method but just figure out the design based on [url]www.flickr.com/tour[/url] section of this site. I must have … | |
I have a variable that contains the name of another variable. I intend to read the contents of the variable name. how? | |
hello can you help me when i click the add button it will not add to the database.it will generate an error..can you help me please hoping for your positive responds...here's my code,please see my attachment.... [CODE] import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.event.*; import javax.swing.JPanel.*; import java.sql.*; public … | |
rectangle r1=new rectangle(); rectangle r2=r1; whats the working of second line here | |
a print procedure is a good candidate for a dynamically bound method. why? | |
I have three classes in the program. This is a part of my assignment. I am doing it for the first time; so you might find something stupid in there.. as i have just tried to get the output my way or based on the assignment requirements. I have one … | |
i hv written code of seraching specific folder on user choice with threading implemented. but im getting nullpointer exception at l.statsWith() in thread class two and not with normal searching [CODE]public class onlyfolder { static String z,l,w,e; static String y; static File f; static JFrame frame; static JPanel panel; static … | |
Hey guys. I have a tic tac toe game that plots random X's and O's on a 2d matrix array called theBoard[row][col]. I want to check to see if one X is placed on 1 spot, and if another point is plotted in the same spot, to check if it … | |
I'm pretty lost on this. I have no idea how to get my program to work. Basically, when an option is selected a price should show up in the text box automatically. Thank you all for your help. Exception in thread "AWT-EventQueue-0" java.lang.ClassCastException: javax.swing.JComboBox cannot be cast to javax.swing.JTextField at … | |
Morning People I seem to be having a pretty big issue with a buffer I have that is reading a text file and acting upon the results of the file, As of now, the buffer reads each token in the file, and stores each token into a variable, this is … | |
I have to create a program that makes a lottery like game. My teacher wants me to use the constructor to initialize all the fields but I can't seem to get it to do that. Everytime I put the fields in the constructor initialized, I get compile errors. So right … | |
Hello! I am having a bit of difficulty calling a function in my class Image. The point of the class is to generate a 2D array of Color instances, then do various things with it. Within my test code, my editor simply will not allow me to call any methods … | |
| I have: [CODE]JButton b1 = new JButton(); b1.setForeground(Color.BLUE); the button labelled b1 turns blue and all is working, However is it possible to use some function like: String ButtonColor = "BLUE"; b1.setForeground(Color.(ButtonColor.getText()));[/CODE] I ask this because i want to get the colour from a different class.. Any help appreciated thanks! |
I am writing here, asking you for a little help. I have assignment in Java for my class in programming. I should create Java Applet and make animation. The animation should consist of several bouncing figures (balls, triangles, squares etc.) and when clicking on them different events should happen. One … | |
The group has now been divided, my problem scenario is the following: There are 2 packing machines, which can pack any type of food, however this needs to be done one at a time. Each food type takes 10 secs to pack. The packing machines get the food from the … | |
Hi I am new to java and I am stuck on an assignemnt and im looking for some suggestions basically i have 8 buttons delcared as an array and i would like to double a number enetered in a textfield when clicking a certian button ..... i want each button … | |
Need Help Solving this problem... How do I start my for loop to display the 7 district aestricks | |
Hi just wondering could anyone help me with this tic tac toe game i am developing it must be a GUI and include AI for the computer i originally made this tic tac toe game without the GUI but i am just having problems converting it to a GUI as … | |
Hello guys......Cindy here I am trying to get my program working and I am getting really frustrated. I am writing this program to familiarise myself with arrays, methods & loops so i can improve my Java skills. Im not lazy guys and have tried searching yahoo ,answers, forums and google … | |
Can someone help me with this please. [CODE]import java.util.Scanner; import java.text.NumberFormat; public class ChargeAccount { private int additional_charges; public int balance; private double min_payment; private int interest; private double new_balance; //initialise Charge Account public ChargeAccount(int previous_balance, int add_charges); { balance = previous_balance; additional_charges = add_charges; Scanner scan = new Scanner … | |
Hi Guys, I've noted that when using Netbeans, .jar file is created when you build your application. if i want executable jar file of my application, can i just take the same generated jar file, or should i create my own .jar via the command prompt. I mean whats the … | |
I am new to this place and have a lot of questions to discuss with all here. Starting with a problem that i am currently stuck in..:) I have a small project for which i am using net beans and want to generate the graph as I am having values … | |
i had stuck with this question cz i'm newbie for java programming. i hope ur helping... The Vote class has the data field count to count votes, and the methods [I]getCount(), setCount(), clear(), increment(), and decrement()[/I] for reading and handling the votes, as shown in class diagram below. The [I]increment … | |
[CODE]void age() { boolean isValid = false; Calendar user = null; while (!isValid) { System.out.print("Enter Date (mm/dd/yyyy): "); DateFormat df = new SimpleDateFormat("MM/dd/yy"); String s = In.in(); Date date = null; try { date = df.parse(s); } catch (ParseException e) { System.out.println("Date error"); } user = Calendar.getInstance(); user.setTime(date); if (user.getTime().getTime() … | |
I have to work on a method called extract feature which has to check for the pattern i pass to the method in the matrix I pass This is an example pattern = {{0,100,0},{255,255,255},{0,100,0}}; Though I pass any different pattern it has to check for that pattern in the matrix … | |
Hello, i'm new to java and i need to read a file of strings into an array and then sort them but i can't figure out how to do either. i can do it with ints and doubles but i can't with strings. if anyone could help me i'd be … | |
[CODE]import java.io.*; import java.util.*; import java.io.FileWriter; import java.io.IOException; public class Dirtrav { public static void main(String args[]) { // String rootDir="C:\\Projects\\PerfBVT'\\W6_TopicVsQueue_8.2.0.0.74_040110\\"; File directory = new File("C:\\Projects\\PerfBVT'\\W6_TopicVsQueue_8.2.0.0.74_040110"); identifydir(directory); } //File directory = new File("C:\\Projects\\PerfBVT'\\W6_TopicVsQueue_8.2.0.0.74_040110\\"); public static void identifydir(File di) { File[] files = di.listFiles(); if (! di.exists()) { System.out.println("Invalid path"); return; … | |
Using WindowsXP Pro SP3 Problem with javascrip I have installed Javascrip Ver 6.0.190.4 When I try to email a site to submit a query I enter the question but when I click on [NEXT] I get this error:mJavascrip:Void ( ) can you help |
The End.