Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Running a console app from a c# gui

Running a console app from a c# gui

Scheduled Pinned Locked Moved C#
csharphelpquestion
5 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    Vodstok
    wrote on last edited by
    #1

    Can this be done? I have a need to use a console application in the background with a c# gui feeding commands and reading output from it. similar, but not limited to something like executing ping, feeding it the url or ip, then reading the responses. Any help would be appreciated.

    ______________________ Mr Griffin, eleventy billion is not a number...:wtf:

    L E 2 Replies Last reply
    0
    • V Vodstok

      Can this be done? I have a need to use a console application in the background with a c# gui feeding commands and reading output from it. similar, but not limited to something like executing ping, feeding it the url or ip, then reading the responses. Any help would be appreciated.

      ______________________ Mr Griffin, eleventy billion is not a number...:wtf:

      L Offline
      L Offline
      leckey 0
      wrote on last edited by
      #2

      Can you be more specific on what is going on in the background? We run console apps from web pages at my new job so I know it can be done. (Unless I have some weird definition of a console application.)

      I have a blog for those with a sense of humor. The codeword is "scuttlebutt." http://craptasticnation.blogspot.com/[^]

      V 1 Reply Last reply
      0
      • L leckey 0

        Can you be more specific on what is going on in the background? We run console apps from web pages at my new job so I know it can be done. (Unless I have some weird definition of a console application.)

        I have a blog for those with a sense of humor. The codeword is "scuttlebutt." http://craptasticnation.blogspot.com/[^]

        V Offline
        V Offline
        Vodstok
        wrote on last edited by
        #3

        ideally, i would run psftp (putty sftp) in the background, feed it connection info and a "get" command and communicate the feedback to the gui app.

        ______________________ Mr Griffin, eleventy billion is not a number...:wtf:

        L 1 Reply Last reply
        0
        • V Vodstok

          ideally, i would run psftp (putty sftp) in the background, feed it connection info and a "get" command and communicate the feedback to the gui app.

          ______________________ Mr Griffin, eleventy billion is not a number...:wtf:

          L Offline
          L Offline
          leckey 0
          wrote on last edited by
          #4

          I'm not real familiar with psftp, but if no one else answers I'll try to do some research at home tonight based on what I know. Sorry I couldn't be more helpful out the gate.

          I have a blog for those with a sense of humor. The codeword is "scuttlebutt." http://craptasticnation.blogspot.com/[^]

          1 Reply Last reply
          0
          • V Vodstok

            Can this be done? I have a need to use a console application in the background with a c# gui feeding commands and reading output from it. similar, but not limited to something like executing ping, feeding it the url or ip, then reading the responses. Any help would be appreciated.

            ______________________ Mr Griffin, eleventy billion is not a number...:wtf:

            E Offline
            E Offline
            Ennis Ray Lynch Jr
            wrote on last edited by
            #5

            Use the Process class and redirect the standard output and standard input streams. I have done it several times. It can be a PITA the way some exes deliver output compared to unix style, unfortunately.

            Need a C# Consultant? I'm available.
            Happiness in intelligent people is the rarest thing I know. -- Ernest Hemingway

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups