Thread: how to redirect the output of a program?

  1. #1
    Registered User
    Join Date
    Sep 2001
    Posts
    18

    how to redirect the output of a program?

    I want to execute a program in C. How to get the output of the executed program?

    Thanks.

  2. #2
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    Posts
    14,826
    Redirection of stdout is OS specific. Commonly you do something like:

    myprog > myoutfile

    Or something similar.

    Quzah.
    Hope is the first step on the road to disappointment.

  3. #3
    Unleashed
    Join Date
    Sep 2001
    Posts
    1,765
    > I want to execute a program in C.

    http://www.cprogramming.com/boardfaq.html#execs

    > How to get the output of the executed program?

    What kind of output?
    The world is waiting. I must leave you now.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 6
    Last Post: 06-05-2009, 09:42 AM
  2. program looping with final output
    By hebali in forum C Programming
    Replies: 24
    Last Post: 02-28-2008, 10:58 AM
  3. Shell output into program during runtime
    By evilkillerfiggi in forum Linux Programming
    Replies: 3
    Last Post: 08-03-2006, 10:50 AM
  4. redirect C output to shell (bash) input
    By deltaxfx in forum C Programming
    Replies: 7
    Last Post: 08-24-2005, 01:55 PM
  5. Redirecting program output straight to an edit control
    By bennyandthejets in forum C++ Programming
    Replies: 5
    Last Post: 07-05-2004, 08:25 AM