Date: Sat, 29 May 93 11:19:03 -0500 From: Tom Hite To: djgpp AT sun DOT soe DOT clarkson DOT edu, russ AT pta DOT pyramid DOT com DOT au Subject: Re: I need some help with static members >Hi, [stuff deleted] >>x.o: Undefined symbol __5thing$i referenced from text segment >>It seems fairly obvious that gcc hasnt allocated the data >>object, so what do I have to do to make it work? Correct. All you've done in the class declaration is specify that somewhere there is a static variable that belongs to the class. YOU have to instantiate that member variable in your class implementation file (or at least somewhere): // header file class A { private: static int m_nCount; public: // other members and whatnot }; ------------ // CPP implementation file int A::m_nCount = 0; // other member variables and whatnot follow -------- Thats it. I hope this is clear... Tom Hite thite AT micrografx DOT com