General discussion

  • Creator
    Topic
  • #2084662

    Call Command Line Program from NT Web Se

    Locked

    by wayne m. ·

    I would like to call a command line utility (Oracle’s tnsping) from a web page on a WindowsNT server. This is merely a way to give users a feel for whether the database is up and running and how responsive it is.

    Any ideas on how to call a command line function and redirect the response back to a web page? I would prefer server side only code, but can live with some client side. I could probably do a COM module, but was hoping for something simpler.

All Comments

  • Author
    Replies
    • #3779964

      Call Command Line Program from NT Web Se

      by kirya ·

      In reply to Call Command Line Program from NT Web Se

      You can use AspExec from http://serverobjects.com/products.htm#free

      And use page Some_Title.asp with following content:

      — Header —
      <% Set Executor=Server.CreateObject("ASPExec.Execute") Executor.Application = "tnsping" strResult = Executor.ExecuteDosApp Response.Write " tnsping returned : " & strResult %>
      — Footer —

      Or, may be you can execute .bat-file on your server as CGI program.

Viewing 0 reply threads