adding header file in existing win32 library.

Hi All,
I have an existing win32 class library. For some recent changes in my project i want to include <vector> header file.
I am completely new so i went to Heder folder of my application ->Right Click ->Add New Item -> New header file( which i named same as vector.h)

But it gave me an error showing that xFunctional header in missing in vector class
I repeated the same process to add up this new header file->xFunctional header.

Finally i was not able to compile the program because it gave error for all the tags "<" in the xFunctional header.

I have following questions.
1. Is my approach correct? please suggest me.

2.I am wondering as - Whats the role of header files in any class library. If i make a simple class in header file(.h), then do i need to make similar function in the .cpp file? ( I would appreciate if someone can just give me little direction on this point.

Thanks in advance.
It seems that there vector is a part of std. so i used

#include<vector>
using namespace std;

and then my code ...so it started working . Still i really dont understand this logic.
Would appreciate if someone tries to answer these queries.
You only need to add YOUR OWN headers to project, not the ones that came with VS compiler (that ones is listed automatically under "aditional depedency" column).
Topic archived. No new replies allowed.