std::string function(std::string buffer)
{
int Variable1 = 23;
if( !buffer.compare("Variable1")) <--- i want the user to input the variable name..and have my program match the input with the variable name of the program and return the value it contains
return Variable1; [U]<--- How do i convert this number into a c++ std::string?[/U]
}
return "turd"
lochnessmonster 0 Junior Poster
gerard4143 371 Nearly a Posting Maven
pseudorandom21 166 Practically a Posting Shark
Caligulaminus 35 Junior Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.