Click to See Complete Forum and Search --> : CString in Class Definition (Header File)


Matthias S
September 21st, 1999, 04:21 AM
Hello,

I have written a class. Now I would like to include a public Method that takes a vector<CString> pointer as a paramter. The cpp file of the class includes MFC so there is no problem. But I get an error, because the compile complains, that the types vector and CString are not known (in the header). Do I have to include MFC into my Header file or how do I solve such problem?

Thanks a lot.



Best wishes,

Matthias Steinbart

Jack Shainsky
September 21st, 1999, 04:46 AM
You have either include the MFC (afx.h) and vector headers in your header time, or always include these files BEFORE including your header in cpp file.

Jack.