Link to home
Start Free TrialLog in
Avatar of arefe
arefe

asked on

unresolved external symbol "private: static char

I have created an application consisting of 1 base class and a number of sub classes. The definition of the base class is like:
class StaticBase {
    static char myC;
  public:
    static void setMyC();
};
When linking the program with MS VC++ 5.0, I get this error:
StaticBase.obj : error LNK2001: unresolved external symbol "private: static char  StaticBase::myC" (?myC@StaticBase@@0DA)
What am I doing wrong?

Avatar of kotan
kotan
Flag of Malaysia image

missing ; on the end of class declaration

class base {
   ...
};
ASKER CERTIFIED SOLUTION
Avatar of glebspy
glebspy

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial