How to close application on Windows?

Discussion in 'Ruby' started by olek, Jul 1, 2004.

  1. olek

    olek Guest

    Hi,
    I need to open some application from ruby on WinXP, get some action
    connected to that app. and close it.

    thread= Thread.new(0) {
    system("abt.exe") # opening my app.
    }
    sleep(20) # time for start abt.exe
    #getting data from abt.exe
    system("hptcmd export")
    #closing abt.exe - it doesn't work!!!!
    Thread.kill(thread)
    #abt.exe still active

    Maybe I should kill a procces connected to that application so the
    application would be closed ....?

    Thanks for every advice
    Mariusz
     
    olek, Jul 1, 2004
    #1
    1. Advertisements

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. Denon
    Replies:
    1
    Views:
    776
    Saravana [MVP]
    Nov 14, 2003
  2. RJN
    Replies:
    2
    Views:
    5,357
  3. =?Utf-8?B?UGF1bA==?=

    How to close all windows in a web application?

    =?Utf-8?B?UGF1bA==?=, Nov 22, 2004, in forum: ASP .Net
    Replies:
    7
    Views:
    1,201
    Lau Lei Cheong
    Nov 25, 2004
  4. Daniel Albisser
    Replies:
    1
    Views:
    1,431
    GaryM
    Apr 7, 2004
  5. Replies:
    6
    Views:
    9,337
    sateeshranga
    Aug 7, 2008
  6. Dani
    Replies:
    3
    Views:
    658
  7. Iñaki Baz Castillo
    Replies:
    7
    Views:
    1,282
    Iñaki Baz Castillo
    Jan 12, 2010
  8. Replies:
    3
    Views:
    616
    Chung Leong
    Jan 16, 2005
Loading...