3,927 Posted Topics
Re: This is accomplished with sockets via http. See if this helps: [url]http://www2.sys-con.com/itsg/virtualcd/Java/archives/0204/dibella/index.html[/url] | |
Re: e.getSource() returns the component that generated the event, which in your case is the combo box. You cannot cast that JComboBox reference to a JTextField. | |
Re: Better start learning how to draw then: [url]http://java.sun.com/docs/books/tutorial/2d/index.html[/url] Come back and post code and specific questions when you have them. | |
Re: liujanet, if you copy all of your answers from the internet, you are going to remain "completely computer science idiot". Study, think, and ask specific questions about the parts you don't understand. If you expect to paste homework and get the answers to turn in, you've wasted your time and … | |
Re: Generally, it's done like this[code]String line=null; while ((line = in.readLine()) != null) { System.out.println(line); }[/code] | |
Re: You'll probably need to use [URL="http://java.sun.com/docs/books/tutorial/uiswing/layout/gridbag.html"]GridBagLayout[/URL] to achieve the degree of control you want. | |
Re: For website review, you can make a post in the [URL="http://www.daniweb.com/forums/forum55.html"]Website Reviews[/URL] forum with a link to your site. | |
Re: The basics of Comparable really come down to returning a negative value if "this" is less than the object passed, a positive value if "this" is greater, or zero if they're equal[code]class SomeClass implements Comparable<SomeClass> { public int compareTo(SomeClass other) { // If this < other, return -1 // If … | |
Re: You can use: ExceptionCode.values()[code]; to access the values array by declaration index. (I can't put that in code tags though because it contains half a code tag :) ) | |
Re: You haven't posted enough code for anyone to help with this. What context are those calls being made in? What is "fixdecimal"? | |
Re: It's a copy of a broken color tag from javaAddict's code above. The bold and color tags don't work right with the java syntax highlighting in code tags. That line should just read[code]Scanner sc = new Scanner(input);[/code] | |
Re: Haven't you learned anything from your previous posts asking others to do your work for you? Get to work and show some effort. | |
Re: The first two posts both gave links on how to accomplish this. Did you read them? | |
Re: Please post the exact exception info when you are referring to one. We can't quite see over your shoulder from here. One thing to note first. You are declaring new variables and initializing them in the constructor[CODE] public PayrollTracker() { final int NUM_EMPLOYEES = 7; int[] employeeID = {5658845, 4520125, … | |
Re: The docs are not vague. Did you bother to read the [URL="http://www.jdom.org/docs/faq.html"]FAQ[/URL]? Just download the jar files and add them to your Netbeans project. If you don't know how to do that, read the Netbeans help files. | |
Re: You really should consider using a Timer for your slideShow() method and ditch doPause(). You don't want to use a loop like that for pausing. [url]http://java.sun.com/docs/books/tutorial/uiswing/misc/timer.html[/url] | |
Re: General 2D graphics: [url]http://java.sun.com/docs/books/tutorial/2d/index.html[/url] 2D space invaders game: [url]http://www.cokeandcode.com/spaceinvaderstutorial[/url] More animation: [url]http://lmgtfy.com/?q=java+animation[/url] | |
Re: You should refer to: [url]http://java.sun.com/docs/books/tutorial/2d/index.html[/url] | |
Re: [QUOTE=VernonDozier;1164679]But I have been confused for a while. What exactly is this fake signature everyone keeps talking about? I see it referenced all over the place, but I have no idea what it is.[/QUOTE] A fake signature is when they put the sig and links directly within the message body, … | |
Re: Looks to be [URL="http://ecommerce-resources.prostores.com/stores/Ssml%20Online%20Reference"]ProStores markup[/URL]. | |
Re: You'll need a mechanism to associate the Light or Door object with the action for a given menu item. One way you might do it is with an action listener that takes a reference to the object you want to operate on, such as[CODE]class LightOnAction implements ActionListener{ Light light; public … | |
Re: What do you need to use them for? Typically you would get them from a MouseEvent with a MouseMotionListener on the component that needs to respond to them. | |
Re: Try looking through the Sun tutorial on [URL="http://java.sun.com/docs/books/tutorial/uiswing/components/editorpane.html"]How To Use Editor Panes[/URL] as a starting point. Also, be sure to look over [URL="http://java.sun.com/docs/books/tutorial/uiswing/components/generaltext.html"]Text Component Features[/URL] | |
Re: Have you tried creating linked tables in an Access database to the MySQL data? You might be able to pull it through DTS that way. MySQL dump files fed into the bulk loader for MS SQL may be another possibility. | |
Re: The quickest and easiest way is to use icons within labels. Take a look at this tutorial: [url]http://java.sun.com/docs/books/tutorial/uiswing/components/icon.html[/url] | |
Re: Well, you are off to a good start by choosing to hijack an old thread in the [B]Java[/B] forum to ask someone to walk you through it. Post your question in the C++ or C# forum and don't be surprised if you get very general answers to such a general … | |
Re: Have you compiled Gen.java yet with 'javac'? | |
Re: [QUOTE=idlackage;1180487]Dumb question, but I've searched everywhere and found nothing specific: is it possible for HSB values to translate directly into a colour (eg. a hue of zero equals red) instead of passing them through an RBG conversion?[/quote]See [URL="http://java.sun.com/javase/6/docs/api/java/awt/Color.html#getHSBColor(float,%20float,%20float)"]Color.getHSBColor(float,float,float)[/URL] [QUOTE=idlackage;1180487] Also, dumber: I'm not understanding the arrrays people are using, for … | |
Re: isCellEditable() gets called by the table when you double click a cell to see whether or not to the editor should be invoked. If you want to respond to a data change immediately, you'll need to use a TableModelListener most likely. | |
Re: You can see an example of drawing multiple shapes here: [url]http://www.daniweb.com/forums/post951298.html#post951298[/url] The point of that post was to show how make a shape draggable with the mouse, but you should get the idea of how to draw more shapes pretty easily. | |
Re: Please be advised that this is not the place to request work for hire or to offer services for such. The proper place for such exchanges is the Business Exchange forums. If the discussion cannot be kept to a technical discussion nature, I will close the thread. | |
Re: I'm curious why you chose to drop this thread: [url]http://www.daniweb.com/forums/thread271568.html[/url] and start a new one when you're still working on the same thing? Did you get the program to work without these extra Point collections and just want to modify it now? | |
Re: You would probably have a much easier time with GridBagLayout instead. | |
Re: Post the stack trace from the "crash". If you don't have one, put that your whole click handler block in a try-catch and print the stack trace in the catch block. | |
Re: Okay. First, you need to read the rules: [QUOTE]We strive to be a community geared towards the professional. We strongly encourage all posts to be in full-sentence English. Please do not use "leet" speak or "chatroom" speak.[/QUOTE] [QUOTE] Do not piggyback threads (aka "hijack" threads) by posting your question as … | |
Re: Here's a very simple line example[code] import java.awt.Color; import java.awt.EventQueue; import java.awt.Graphics; import javax.swing.JFrame; import javax.swing.JPanel; public class LinePaintDemo extends JPanel{ @Override protected void paintComponent(Graphics g) { super.paintComponent(g); g.setColor(Color.BLUE); int width = getWidth(); int height = getHeight(); int midX = width/2; int midY = height/2; for (int x=0; x<=midX; x+=3){ … | |
Re: Take a look at the following re: equals() and hashcode() [url]http://www.ibm.com/developerworks/java/library/j-jtp05273.html[/url] | |
Re: No, you have come to the wrong site if you want a program given to you. If you start a new thread, post your code, and ask specific questions, someone may be able to [U]help[/U] you with it. | |
Re: Use getResource() to load the images instead of the simple path[code=java]ImageIcon qmarkIcon = new ImageIcon(getClass().getResource("images/mark.gif"));[/code] More info on this here if you want to understand the nuances: [url]http://java.sun.com/docs/books/tutorial/uiswing/components/icon.html#getresource[/url] | |
Re: ... [quote]User: Nah, you're Ashamed. Cleverbot: I am Nive Cleverbot. User: You are Ashamed. Cleverbot: I'm not! I'm Nick. User: Just making things up now, eh? Cleverbot: You will not be lonely if you are talking with me. User: I'm not lonely. Cleverbot: You're overworked. User: No, I don't think … | |
Re: Please do not create multiple threads for a single question. You already have an existing active thread for this question here: [url]http://www.daniweb.com/forums/thread270642.html[/url] Please direct any further discussion to that thread. | |
Re: Perhaps you just need to revalidate() the panel after you've added the new components? | |
Re: I guess you didn't read this announcement at the top of the forum: [url]http://www.daniweb.com/forums/announcement51-58.html[/url] | |
Re: >This new look is stupid. ... Yeah! Rabble, rabble, rabble!!11! Sorry to hear that you are feeling sick. Perhaps you just need some fresh air. (This thread didn't though...) | |
Re: The reviews for the 9500 weren't too great. Perhaps you should just return it and consider another from this article: [url]http://www.tomshardware.com/reviews/radeon-geforce-graphics,2086.html[/url] The HD 4670 sounds like a pretty good card for ~$80. | |
Re: Are you saying that you don't know how to parse the value you are getting? Or that you aren't able to capture the response at all? | |
Re: Don't try to execute "Creature.java" - execute "Creature" after you have compiled to a class file. |
The End.