executing shell commands in asp

Discussion in 'ASP General' started by mlay, Nov 9, 2003.

  1. mlay

    mlay Guest

    Hi,

    I'm trying to execute a Windows command in ASP. For example, this is a
    snippet of what I have right now:
    ....
    Set WshShell = WScript.CreateObject("WScript.Shell")
    WshShell.Run("notepad", 1, true)
    Set WshShell = Nothing
    ....

    The strange thing is that notepad.exe actually appears under the list of
    processes in Task Manager, but its window does not show up on the server's
    desktop; the client's browser just sort of hangs. I'm led to believe that
    this has something to do with IIS permissions, but I'm not certain. If
    anyone could help out, I'd really appreciate it. Thanks in advance.

    Meng
     
    mlay, Nov 9, 2003
    #1
    1. Advertising

  2. mlay

    Ray at Guest

    What you're failing to realize is that the notepad.exe process is launching
    under the IUSR's processes, and the IUSR isn't logged onto the machine with
    a desktop. You won't see it on the server's desktop.

    Ray at home

    "mlay" <> wrote in message news:bokkuc$i97$...
    > Hi,
    >
    > I'm trying to execute a Windows command in ASP. For example, this is a
    > snippet of what I have right now:
    > ...
    > Set WshShell = WScript.CreateObject("WScript.Shell")
    > WshShell.Run("notepad", 1, true)
    > Set WshShell = Nothing
    > ...
    >
    > The strange thing is that notepad.exe actually appears under the list of
    > processes in Task Manager, but its window does not show up on the server's
    > desktop; the client's browser just sort of hangs. I'm led to believe that
    > this has something to do with IIS permissions, but I'm not certain. If
    > anyone could help out, I'd really appreciate it. Thanks in advance.
    >
    > Meng
    >
    >
     
    Ray at, Nov 9, 2003
    #2
    1. Advertising

  3. Why would you want to execute an exe with a GUI from ASP? Who's going to
    sit at the server waiting to interact with a GUI?





    "mlay" <> wrote in message news:bokkuc$i97$...
    > Hi,
    >
    > I'm trying to execute a Windows command in ASP. For example, this is a
    > snippet of what I have right now:
    > ...
    > Set WshShell = WScript.CreateObject("WScript.Shell")
    > WshShell.Run("notepad", 1, true)
    > Set WshShell = Nothing
    > ...
    >
    > The strange thing is that notepad.exe actually appears under the list of
    > processes in Task Manager, but its window does not show up on the server's
    > desktop; the client's browser just sort of hangs. I'm led to believe that
    > this has something to do with IIS permissions, but I'm not certain. If
    > anyone could help out, I'd really appreciate it. Thanks in advance.
    >
    > Meng
    >
    >
     
    Aaron Bertrand [MVP], Nov 9, 2003
    #3
    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. Daniel Portal

    Executing DOS commands from ASP.NET

    Daniel Portal, Nov 18, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    3,666
    Lau Lei Cheong
    Nov 19, 2005
  2. Kentor

    executing shell commands from c?

    Kentor, Mar 19, 2007, in forum: C Programming
    Replies:
    10
    Views:
    799
    Ben Pfaff
    Mar 20, 2007
  3. Kevin Skrenes
    Replies:
    6
    Views:
    235
    Robert Klemme
    Mar 17, 2007
  4. Guilherme Viteri

    Ruby executing shell commands

    Guilherme Viteri, Sep 8, 2010, in forum: Ruby
    Replies:
    2
    Views:
    232
    Roger Pack
    Sep 8, 2010
  5. Murugesh
    Replies:
    5
    Views:
    194
Loading...

Share This Page