Thread: Program Not Producing Output

  1. #1
    Registered User
    Join Date
    Mar 2011

    Program Not Producing Output


    So I have a basic program that uses a
    command to open up a file and run it using its default program (a simulation program). My simulation is able to finish, but does not produce the output that it usually does (it produces .dat files contain data of the simulation run in the same folder as the simulation .hnb file) (when I run the simulation outside of my C program it produces output just fine). I am thinking that this may have something to do with the permissions of my C program. Any thoughts/advice? Thanks
    Last edited by lebronlin; 04-28-2011 at 12:03 PM.

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    The edge of the known universe
    Use say getcwd() to find out what the current directory is when you call system()
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  3. #3
    Registered User
    Join Date
    Mar 2011
    Hahahaha thanks.....I feel really stupid, I can't believe I didn't check the program file directory for the output, instead of the simulation file directory

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Supreme Court - Producing IDs to police
    By Thantos in forum A Brief History of
    Replies: 23
    Last Post: 06-22-2004, 06:37 PM
  2. Producing Beep Sound with C++
    By ron4ldk in forum C++ Programming
    Replies: 8
    Last Post: 05-01-2004, 01:05 AM
  3. Help producing sine wave
    By ricky1981 in forum C++ Programming
    Replies: 9
    Last Post: 10-31-2003, 09:20 PM
  4. Producing a random number
    By Dauthi in forum C++ Programming
    Replies: 2
    Last Post: 09-03-2002, 07:25 AM
  5. producing random numbers???
    By esilja in forum C++ Programming
    Replies: 3
    Last Post: 10-19-2001, 07:48 PM