Archived

This topic is now archived and is closed to further replies.

chillah

Windows question

Recommended Posts

Ok, say I am making a game (wow, think of that) and I have multiple files. Say I make one .h file with all of the main includes and variables used in almost every file. I include this .h file into all of the .cpp files. Almost every file has at least one function that requires the handle of the main window. My question is this: Can I use extern to put the handle of my main window in the .h file that I include in all of my other files.? Would this work? Edited by - chillah on November 16, 2001 3:26:53 PM

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Yep. Just try it.

But you have to define the handle in one of the implementation files (without extern).

Share this post


Link to post
Share on other sites