Thread: can C work outside the terminal or CMD window?

  1. #1
    Registered User
    Join Date
    Jul 2010
    Posts
    1

    Question can C work outside the terminal or CMD window?

    Brief intro
    Without giving you a long winded background just know that I only started to use C few months ago and know no other programming language. Although I aim to go into iphone development I am prepared to take slow steps towards it, and will look at programs like C++ and Objective-c when i am confident with C.
    Now my question is, is C just so very limited? Its ok my writing programs that run loops and check for certain conditions to be met and having the results of some users input show on the screen but is that all it does??
    Is it possible to run a C built program outside of the CMD or terminal windows? Can C read/write data from a file and store it? seems a bit pointless that every time I close my terminal window any info i get be it an solution to a math problem or working out a cross reference that the data is lost, and not stored.
    Lets say I want to build and run a piece of code that works in its own environment without the user having to run it through CMD or terminal is this at all possible or am I quickly find the limits with C.
    I appreciate your comments,
    Last edited by Salem; 07-22-2010 at 09:00 AM. Reason: Changed to quote tags, so it wraps

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    You can do whatever you want.

    The only downside is that you have to put a LOT more effort into some things, compared to other languages. Most of the time, it's about finding a good set of libraries which do most of the grunt work for you (say a GUI framework), and you can focus on what is special to your application.

    It might seem like a weakness to you, but C can be used for anything between your wrist-watch to a super-computer cluster.

    > Is it possible to run a C built program outside of the CMD or terminal windows? Can C read/write data from a file and store it?
    Yes and Yes

    Look up fopen etc to see how to write data to a file.
    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
    Third Eye Babkockdood's Avatar
    Join Date
    Apr 2010
    Posts
    352
    C is a lot more powerful than you think. If you want to save console output to a file, just type "> ./OUTPUT.TXT" after a command.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. creating a child window
    By rakan in forum Windows Programming
    Replies: 2
    Last Post: 01-23-2007, 03:22 PM
  2. Adding colour & bmps to a Win 32 Window??
    By carey_sizer in forum Windows Programming
    Replies: 4
    Last Post: 09-04-2004, 05:55 PM
  3. System
    By drdroid in forum C++ Programming
    Replies: 3
    Last Post: 06-28-2002, 10:12 PM
  4. Tab Controls - API
    By -KEN- in forum Windows Programming
    Replies: 7
    Last Post: 06-02-2002, 09:44 AM
  5. Winamp Vis if anyone can help
    By Unregistered in forum Windows Programming
    Replies: 6
    Last Post: 01-27-2002, 12:43 AM