Thread: [Help]C++
View Single Post
Old 01-13-2011   #22
Google

 
Google's Avatar
 
Last Online: 05-30-2013
Join Date: Jan 2008
Posts: 1,788
Thanks: 10,018
Thanked 1,100 Times in 651 Posts
Groans: 1
Groaned at 6 Times in 6 Posts
Default

You cannot initialize data member like that unless it is declared as static const. Or if you wanna do this, do it in the constructor. As for the second error, just add Stock() { }; and you will be fine.
__________________

Google is offline   Reply With Quote