Possible Duplicate: int to std::string?
How can you convert int to std::string?
you can use stringstream; stole this from here:
#include <iostream> #include <sstream> int main() { int number = 123; std::stringstream ss; ss << number; std::cout << ss.str() << endl; }