Search:

Type: Posts; User: piulitza

Page 1 of 3 1 2 3

Search: Search took 0.18 seconds.

  1. Replies
    2
    Views
    1,833

    How to compile this project inside Eclipse?

    I am currently going through a JPPF (Java Parallel Processing Tutorial) and for this, I downloaded some folders with libraries and classes that are some kind of templates for a project using this...
  2. How to make a program to "sleep" until my Thread ends

    I have a problem with a program that I try to make. Inside a JFrame class, I start one Thread. That thread checks something and return a boolean as true or false. Inside the JFrame class I want to...
  3. Replies
    4
    Views
    1,512

    Re: Need help to export .jar file

    I tried to do like that but I only got nullpointer exceptions. I ended with creating JButton class and drawing each button there inside the paintComponent method. Like that I no longer needed any...
  4. Replies
    4
    Views
    1,512

    Need help to export .jar file

    I have created one program with GUI using Eclipse. I need to export it as a runnable .jar file. I do exactly as I seen on some tutorials.
    My problem is the following:
    Many of my buttons have...
  5. Replies
    4
    Views
    1,457

    Re: Why FilenameFilter is never working?

    By not working I mean for example if i set the Loading FilenameFilter with ".txt", it will not show only .txt files as I wanted, it still shows all files in the folder!!!
  6. Replies
    4
    Views
    1,457

    Why FilenameFilter is never working?

    While coding in Java, I did many programs with GUI at which I needed to save something to a file. I usually use FileDialog to save something. Sometimes I wanted to filter the names of files that I...
  7. How can I make a JDialog to make main Frame to "sleep"

    I have one question. I noticed that when I use a FileDialog, every command that follows making the FileDialog to be visible only continues only after I close the FileDialog.
    But I am looking to make...
  8. Replies
    1
    Views
    1,217

    Question about MouseListener

    I have a problem with using MouseListener.
    I am working to make a simulator for some electronic devices. I have some buttons for each kind of component I want to draw on a Canvas area. And if I...
  9. Re: JAVA AWT GRAPHICS REMOVE SOMETHING THAT IS DRAWN

    You can paint that component again with the background's colour, usually white.
  10. why i cannot use this class if working with another workspace?

    I want to make a program that uses some of the Java Media Framework classes. I have the following problem:
    In this object declaration:



    private MediaLocator mediaLocator = null;


    I use...
  11. Re: What is the best way to read from a text file?

    There is one more way to read from a file: using Scanner class. You can use this constructor:


    Scanner in = new Scanner (new File(url));


    And after you can read Strings from the file, or...
  12. Replies
    15
    Views
    3,551

    Re: help with JButton closing a JFrame :)

    Try to use

    or


    These should work better to close a JFrame
  13. Replies
    3
    Views
    3,698

    Re: Need help to save Canvas content to a file

    I made a smaller program to make it easier to put here:
    Here is a class which extends Canvas. Inside the method paint i draw a String. And, i add mouselisteners to make it possible to draw on the...
  14. Replies
    3
    Views
    3,698

    Need help to save Canvas content to a file

    I have worked for a while to make a paint-like program. The area that i use to draw is a Canvas. Now, i want to save whatever i draw on it ...to a file on my harddisk. I have tried like this:


    ...
  15. Replies
    1
    Views
    1,047

    Why does it enter this if ?

    I am working to make a kind of paint. I got stuck to something that i do not understand. Look here the fragment of code which is making problem:



    System.out.println("forma: " + fp.forma);
    ...
  16. Replies
    13
    Views
    3,216

    Re: I am trying to make a messenger program!

    Hah ...finally i managed make it work ....i should have not changed the filesize variable to the size of the file....because it makes that bytearray length and current to have same value...so that is...
  17. Replies
    13
    Views
    3,216

    Re: I am trying to make a messenger program!

    Well , seems there is something wrong with Threads that send/receive the file.
    I made some classes separated from the messenger project, and i discovered that they actually have a problem (not the...
  18. Replies
    13
    Views
    3,216

    Re: I am trying to make a messenger program!

    Yeah, that works properly! The size of the file is sent to the main serversocket of my messenger, inside the String containing the word FILE. I have "cut " the String and got the size from that...
  19. Replies
    13
    Views
    3,216

    Re: I am trying to make a messenger program!

    Yeah, you are right. I think it cannot send a .bmp file properly, or maybe it cannot crate a bytearray that large, as the bmp file dimension. I tried to send a .txt file which is smaler and it...
  20. Replies
    13
    Views
    3,216

    Re: I am trying to make a messenger program!

    So far, i manged to make it work fine with sending text message. Now i want to make my messenger to send a file from one user to the other. But i do not manage to make 2 simple sockets to send one...
  21. Replies
    1
    Views
    1,492

    Problem with FileReader

    I have to make a program at which i have to read something from a file using FileReader.
    I write here the fragment of the code which reads an integer from the file :



    try
    {
    FileReader...
  22. Replies
    4
    Views
    1,762

    Which tutorial should i choose?

    So far, at Java i learned how to work with streams, with Threads and how to make GUI using AWT or Swing components; i also learned how to make an applet. I want to make step forward. I heared that it...
  23. Replies
    13
    Views
    3,216

    Re: I am trying to make a messenger program!

    basically on each computer should run 2 Threads:
    one of them sends the message having the role of server and the other one receives the message having the role of client!
  24. Replies
    13
    Views
    3,216

    I am trying to make a messenger program!

    I got to do a kind of Messenger in Java. Well .. it will not have to do something with a server or making accounts. Will simply be a program which will be used to communicate between 2 computers into...
  25. Replies
    6
    Views
    2,146

    Re: Need help to run my first applet

    Yeah, it worked !! It is good to know i should not create the applet classes inside the packages.
Results 1 to 25 of 53
Page 1 of 3 1 2 3