|
-
October 30th, 2009, 09:54 AM
#1
external or global function problem
Hi all,
I am using MFC dialog application and I have some global variables.
I am struggling with where and how I can declare an external function to make initialization for external or global variables and this function should bring the values from DB to store them in those global variables.
I tried to put the desired code without include them inside function structure after the ProjectNameApp theApp in the ProjectName.cpp// but failed
I tried to put the function declaration as a member function in the ProjectNameApp class and call it after the ProjectNameApp theApp in the ProjectName.cpp //but failed as well
I tried to put the function declaration as a member function in the ZZ.cpp and made the proper including //but failed and inform me that you can't initialize them into closed scope.
it seems to me that the initialization should be in the test.cpp and without function using. I don't believe that but how I can make it.
Please any one can help me?
Any help will be appreciated
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|