Thread: Constant across Files - newbie in C !!

  1. #1
    Registered User
    Join Date
    Dec 2004
    Posts
    1

    Constant across Files - newbie in C !!

    Hi,
    I'm new in C programming. I've one problem, I have to deploy some kind of flags in several functions in different files. This flag can be a Int value. I've to check the flag value in one file, suppose test.c, but the flag is changed in a different file.

    What suggestions, aproach do you have?

    Thanks in advanced!

  2. #2
    Gawking at stupidity
    Join Date
    Jul 2004
    Location
    Oregon, USA
    Posts
    3,218
    If you understand what you're doing, you're not learning anything.

  3. #3
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    extern is a C keyword that just tells the compiler that variable that succeeds it will be declared in another file, to be linked in later.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Error opening files in a different dir
    By Ozzie in forum C++ Programming
    Replies: 3
    Last Post: 10-09-2008, 06:55 AM
  2. Working with muliple source files
    By Swarvy in forum C++ Programming
    Replies: 1
    Last Post: 10-02-2008, 08:36 AM
  3. Program Deployment and DLL/OCX Files?
    By dfghjk in forum C++ Programming
    Replies: 5
    Last Post: 06-16-2008, 02:47 AM
  4. Newbie: Huge EXE files for simple programs - why?
    By Dominic in forum A Brief History of Cprogramming.com
    Replies: 14
    Last Post: 10-11-2002, 04:07 PM
  5. reinserting htm files into chm help files
    By verb in forum Windows Programming
    Replies: 0
    Last Post: 02-15-2002, 09:35 AM