32,199 Topics
| |
After compiling this code, I am getting a "cannot find symbol constructor Timer(int,Morning)" on line 17. [CODE]import java.awt.*; import java.awt.event.*; import javax.swing.*; public class Morning extends JFrame { private EasySound rooster; private int time; /** * Constructor */ public Morning (int time) { time = 0; Timer clock = new … | |
Hi, i am trouble to connect with sqlserver 2005 in windows authentication mode which do not contains username and password it will give me an error like connection failed for user ''(blank) here is my connection string [CODE]string URL="jdbc:sqlserver:\\localhost:1433;dbname"[/CODE] can anybody help me please | |
Hi , My name is Dennis a DBIT student.I am kindly asking for assistance in any of the following questions .It's part of my research so i kindly request if you would explain to give me a better understanding and also equip me with the knowledge of handling questions of … | |
hey guys. OK so, I've been wondering this for a while now. my code is always so unnecessarily cluttered because I don't know how to do this, lol. say I have a set of private class variables: [code=java] private ArrayList row0 = new ArrayList<String>(); private ArrayList row1 = new ArrayList<String>(); … | |
Hi, I'm developing a new Java applet and it requires a 3d engine to import a 3d model with a texture wrapped around the model. Then the user will be able to browser around the model in like a first person shooter style but just browse/look around, nothing else. Does … | |
C++ was once the King of programming. It would crush any competitor! But, now it seems that C++ is getting less popular. New programmers are rushing to easier to learn, higher level, programming languages (e.g. Java). And with Microsoft coming out with C# which is gaining popularity (even though it … | |
Hi all Can someone tell me the difference between public static void main and private static void main? What is public and what is private and static? Thanks guys+girls | |
Hi everyone. I am new to java programming and taking a class in college. I got to a problem which I can do but i don't know the correct way to do it. It says to use mutator and accesor . can you please explain what should i change? I … | |
I'm trying to use bufferedImage to display the bac[ICODE][/ICODE]kground of my application but i'm not successful. I don't get what's wrong with it here's the part of the code: [ICODE] Graphics g; BufferedImage offscreen; offscreen= ImageIO.read(new File("mainScreen.png")); g.drawImage(offscreen, 0, 0, null); [/ICODE] and i use the paintcomponent() here : [ICODE] … | |
hey i got this 3d cube that rotates and does other cool nonsense HOWEVER i cant figure out how to color it. Need to do it with out using java 3d and i DO know about the painters algorithm, i just dont know exactly how to go about implementing it … | |
public class Employee { private String Name; private String SIN; private Integer Salary; public Employee(String string, String string2, int i) { // TODO Auto-generated constructor stub } public Employee() { } public Employee(String N, String sin, Integer Sal) { Name = N; SIN = sin; Salary = Sal; } public … | |
Hey all, I've been struggling for the past few days with a "recursive" function that was driving me crazy till this moment. So, the function takes a list of sublists, each sublist containing a number of strings. Then, the function returns a list of lists of all possible combinations that … | |
The following code works: [CODE] public class Main { public static void main (String args[]){ final JWindow f = new JWindow(); JLabel l = new JLabel(new ImageIcon(Main.class.getResource("images/logo.png"))); f.getContentPane().add(l, BorderLayout.CENTER); f.pack(); Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); Dimension labelSize = l.getPreferredSize(); f.setLocation(screenSize.width/2 - (labelSize.width/2), screenSize.height/2 - (labelSize.height/2)); f.setVisible(true); f.setAlwaysOnTop(true); } }[/CODE] When I … | |
please help me , i really dont have any idea about our project . i need to fix it 1 week before our defense so that i can work well with it and study all about it .. | |
I'm looking for how to brute-force the result of something like [ICODE]"Hi".hashCode()[/ICODE]. I have no idea where to start. I looked for the answer for like 5 hours yesterday. It's for reversing Minecraft seeds. (seed-to-text). I tried my own solution. It's too crap to even post. I tried to find … | |
In Java Create a file using any word processing program or text editor. Write an application that displays the file's name, containing folder size and time of last modification. Save as FileStatistics This is what I have with Attributes errors, what am I missing here ? Thanks <CODE> import java.nio.file.*; … | |
[CODE]import java.io.*; class FinalProject{ public static void main(String[]args){ String name=" ", month, date; int total,cash=0,bal=0,y=0; int r=0; boolean ans=true; int test; do{ try{ FileWriter extend = new FileWriter("extension.txt",true); BufferedWriter out = new BufferedWriter(extend); System.out.print("Welcome! to GLORIA'S FUDHAUZ \n"); System.out.print("Enter date: "); date = Enter.readString(); System.out.print("Enter name: "); name = Enter.readString(); … | |
[CODE] [1]class A{ [2]public static void main(String...agrs){ [3]String str1="ABC"; [4]String str2="ABC"; [5]String str3=new String("ABC"); [6]} [7]} [/CODE] How many objects are created at each line and finally at line 7? | |
Hey guys! I'm working on a console calculator. My problem is that how would I perform the inputted operator? So, if the user inputs "+" and a "-" it will perform those. Here's what I have so far: [code] import java.util.Scanner; public class Calculator { public static void main (String … | |
Hi, its has been a long time since I have used java and I would like some help making this loop as long as you say yes when you say no the loop will stop but not the program [CODE] if (place.equals("swordsmith")) { System.out.println("Hello " + name +"! Would you … | |
So I'm trying to add a while loop so that the program continues to ask for the user to enter a new string phrase after the previous one is counted until the user enters the phrase "quit". However, for some reason if you enter anything but "quit" it just produces … | |
Input file looks like this BASKETBALL John Smith 23 , 54 FOOTBALL Jose Cruise 445, 23 BASKETBALL KJ 34, 32 BASEBALL Mike Beterman 3, 2 FOOTBALL David Smith 323, 23 Below is my code. What is happening on my output I get Sport: BASKETBALL Name: John Smith Stat: 23 , … | |
[CODE] int a [0] = int b [1]; [/CODE] I get this error. [QUOTE]Type mismatch: cannot convert from int to int[][/QUOTE] | |
I want to make node heights of JTree nodes to differ. I mean like the parents have different node height and childs have different node height. I tried to put myJTree.setRowHeight(30) while adding nodes but it doesn't work because it does not work for a single node but for the … | |
My deadlines are running @.@ please help me on how to make a curve fit for this little ballie dude i created. again as a proof of what im doing . can someone help me with this? i need to come up with something like --> ":3" thanks guys. [CODE]import … | |
Hey guys. I am trying to write a programme (not using scanner class) which prints the smallest number in an external text file called README.txt. Anyway I included some explanation of what I am doing so hopefully it's clear. What this programme prints is 0.0, which is not even a … | |
How can I store a number with 10^6 digits in Java? Would BigInteger be the most appropriate while considering performance issues like memory and speed | |
Oh. btw admin! sorry about my earlier thread. i promise not to do something like that ever again :) anyway. i was having trouble with my project and its about Multiplication with loops. i started with a few codes and im really frustrated with what im doing now. please let … | |
I need to generate 500 random numbers from 200 to 1200 and use insertion to sort them. This is probaly simple for you guys but im confused. My problem is when i run the program all I get is 500 0's. Anyone help me out? [CODE]public class insertion{ public static … | |
need help ... i need to have a java code for the feistel block cipher .. i know you can help me ... ' please .. :p -- thank you in advance /.. |
The End.