Click here to Skip to main content
15,887,266 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Hey All,

I am writing a Win32 dll. I included a class that can access database operations. I included afxdb.h in the headerfile and declared a variable in the header file for CDatabase.

When I compile, it gives me a error that windows.h already included. MFC apps must not #include <windows.h>;
Same when I try to include it in the .cpp file (below stdafx.h) it compiles without error.

Can any one help me around this please?
Posted
Updated 24-Jun-10 19:46pm
v2
Comments
Peter_in_2780 25-Jun-10 3:00am    
Reason for my vote of 1
Repost

1 solution

You have already asked this question in the C/C++/MFC forum. What makes you think that asking it again here will help anyone?
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900