C++ extern question
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 14 of 14

Thread: C++ extern question

Threaded View

  1. #1
    Join Date
    Jun 2011
    Posts
    30

    C++ extern question

    MFC application.
    I created a file access class for simple debug stuff that's not needed to run thru the document's serialize. I want to be able to call it from anywhere or any class, so I figured I can just put it global in the app's header file right under the theApp object. I used VC 6 in the past and I don't remember seeing the extern in front of the theApp object. Now I'm using VC 2005 and the project created the app object with extern.

    I assume I should create my class object with extern also ?
    What is the difference in a global object with or without extern ?

    ----In my app's header file--
    extern CViewSwitchApp theApp;
    extern MyFileClass FileClass;
    ----------------------------
    Last edited by J_W; May 9th, 2013 at 06:10 PM. Reason: spelling

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Azure Activities Information Page

Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center