Java Question

Discussion in 'Computer Science & Culture' started by DeFilippis, Jan 31, 2007.

Thread Status:
Not open for further replies.
  1. DeFilippis Registered Senior Member

    Messages:
    52
    Hello,

    I was wondering if someone could tell me or direct me to a source about how to make programs run in the background in Java.

    Thank you,
    Evan
     
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. RubiksMaster Real eyes realize real lies Registered Senior Member

    Messages:
    1,646
    In the background of Windows? I don't even know if you can. The java virtual machine would have to be running, which you don't have control over. It runs in the foreground, so it pretty much ruins your chances of having your application run in the background. At least that's what I think.
     
  4. Google AdSense Guest Advertisement



    to hide all adverts.
  5. Crunchy Cat F-in' *meow* baby!!! Valued Senior Member

    Messages:
    8,423
    Do you mean in the background as in system service or as in no user interface?
     
  6. Google AdSense Guest Advertisement



    to hide all adverts.
  7. Voodoo Child Registered Senior Member

    Messages:
    1,296
    The javaw command is identical to java, except that with javaw there is no associated console window. Use javaw when you don't want a command prompt window to appear. The javaw launcher will, however, display a dialog box with error information if a launch fails for some reason.

    http://java.sun.com/j2se/1.4.2/docs/tooldocs/windows/java.html
     
  8. kl5k Registered Senior Member

    Messages:
    32
    I am not completely sure what you're asking. If you asking about multitasking within your java program, then you want to readup on Threads. You can setup a background thread on a timer tick, for example, to services resources or read a port of some sort. If your talking about a windows service application that runs in the background like a Unix daemon, then you will have to readup on windows services (I imagine there is an API you need to access). I much more knowledgeable about Unix application programming.
     
Thread Status:
Not open for further replies.

Share This Page