• Advertisement
Sign in to follow this  

std namespace not found

This topic is 4450 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

i originally had my class just all defined in a header file...didnt feel like seperating into header and cpp files... but now i had to because i was making a singleton and i need to define some static variables and so on... now in that class im not able to use the std library... ive tried making std::stringstreams or anything Strings... i get errors saying its an undeclared identfier can someone help vs2003 and running winxp thanks

Share this post


Link to post
Share on other sites
Advertisement
If you're using std::string's, you need to make sure you're going #include <string>, and if you want std::stringstream, you need to go #include <sstream>

Share this post


Link to post
Share on other sites
ive tried including stdlib.h but it didnt fix the problem...

in all my other classes i can use std but just not this one class...

Share this post


Link to post
Share on other sites
alright thanks that did it
i included string and sstream


i jsut wasnt doing this before because my other classes are in header files...

thanks for the help

Share this post


Link to post
Share on other sites
Quote:
Original post by StoneDevil
ive tried including stdlib.h but it didnt fix the problem...


stdlib.h isn't the header which contains the things you are looking for. Try including string and sstream.

EDIT: Beaten.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement