I\'m trying to convert a std::string
stored in a std::vector
to an integer and pass it to a function as a parameter.
This is a simplified vers
record[i].c_str
is not the same as
record[i].c_str()
You can actually get this from the error message: the function expects a const char*
, but you're providing an argument of type const char* (std::basic_string
which is a pointer to a member function of the class std::basic_string
that returns a const char*
and takes no arguments.