pausing a process from java

Discussion in 'Java' started by zubairkhan, Feb 23, 2005.

  1. zubairkhan

    zubairkhan Guest

    hi

    i have a task in which i have to run a exe(simulation programme) from
    java. using following code:

    try {
    suzrt = Runtime.getRuntime();
    suzproc = suzrt.exec("cmd /C start suzana test");
    } catch (java.io.IOException exception) {
    System.out.println("Exception!");
    }

    now this exe will be a new process outside java, i need to pause it for
    few seconds and resume it back.

    i allready tried to pause the exe using several windows tools.
    but the main requiremet of the task is that it shall run on diffrent
    platforms like windows and linux).

    how can i do this ?? any one has and idea abt this. help me.
     
    zubairkhan, Feb 23, 2005
    #1
    1. Advertising

  2. zubairkhan

    dar7yl Guest

    "zubairkhan" <> wrote in message
    news:...
    > hi
    >
    > i have a task in which i have to run a exe(simulation programme) from
    > java. using following code:
    >
    > try {
    > suzrt = Runtime.getRuntime();
    > suzproc = suzrt.exec("cmd /C start suzana test");
    > } catch (java.io.IOException exception) {
    > System.out.println("Exception!");
    > }
    >
    > now this exe will be a new process outside java, i need to pause it for
    > few seconds and resume it back.
    >
    > i allready tried to pause the exe using several windows tools.
    > but the main requiremet of the task is that it shall run on diffrent
    > platforms like windows and linux).
    >
    > how can i do this ?? any one has and idea abt this. help me.
    >


    How about creating a socket (UDP?) between the two processes,
    and sending command messages between them. A bit of overkill,
    but it could get the job done.

    regards,
    Dar7yl
     
    dar7yl, Feb 23, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Sharp

    Pausing in Java

    Sharp, Jan 28, 2005, in forum: Java
    Replies:
    4
    Views:
    4,134
    Tony Morris
    Jan 28, 2005
  2. Sebastian Millies
    Replies:
    0
    Views:
    418
    Sebastian Millies
    Oct 6, 2005
  3. gaff
    Replies:
    1
    Views:
    552
    Andrew Thompson
    Dec 1, 2006
  4. Red Orchid
    Replies:
    1
    Views:
    342
  5. yccheok
    Replies:
    1
    Views:
    615
    Piotr Kobzda
    Mar 28, 2008
Loading...

Share This Page