V
Venkat
Hi All,
I am getting unusual compile errors when i declare a vector as a private
member of a class in .h file,
but if i declare the same in .cpp file inside the definition of a function
which is a member of the same class it is working fine.
Here is my .h file
#include <wtypes.h>
#include <string>
#include <list>
#include <map>
#include <set>
#include <vector>
#include <Winsock2.h>
class A{
private:
std::string ExtractServerFromDSN(std::string& dsn);
long CheckPublisher();
std::string m_Database;
std::string m_DSN;
std::string m_Server;
std::string m_UserID;
std::string m_UserPWD;
odbc::Connection *m_Con;
vector<string> CSVTagNameList;
public:
A(void);
~A();
long DBConnection();
int CIDPDBInstall::fn1(const std::string dialPlan);
int CIDPDBInstall::fn2(const std::string dialPlan);
// TODO: add your methods here.
};
CSVTagNameList vector declaration is giving problems, but the same if i use
in .cpp file inside a public function of above class A works fine.
Can someone tell me if i am missing anything.
regards,
Venkat
I am getting unusual compile errors when i declare a vector as a private
member of a class in .h file,
but if i declare the same in .cpp file inside the definition of a function
which is a member of the same class it is working fine.
Here is my .h file
#include <wtypes.h>
#include <string>
#include <list>
#include <map>
#include <set>
#include <vector>
#include <Winsock2.h>
class A{
private:
std::string ExtractServerFromDSN(std::string& dsn);
long CheckPublisher();
std::string m_Database;
std::string m_DSN;
std::string m_Server;
std::string m_UserID;
std::string m_UserPWD;
odbc::Connection *m_Con;
vector<string> CSVTagNameList;
public:
A(void);
~A();
long DBConnection();
int CIDPDBInstall::fn1(const std::string dialPlan);
int CIDPDBInstall::fn2(const std::string dialPlan);
// TODO: add your methods here.
};
CSVTagNameList vector declaration is giving problems, but the same if i use
in .cpp file inside a public function of above class A works fine.
Can someone tell me if i am missing anything.
regards,
Venkat