+ is already overloaded for std::string, it cannot be overloaded for a pair of char*'s or any other POD (plain old data). You are going to have to be more specific about "not working". Does it compile, what string were you expecting, and whats with the \0? If you want a binary zero ebeded in a std::string you need to specify a length when you construct it. Obviously given only a char* you cannot know if the embeded binary zero is part of the string, or marks the end of the string.
Code:
std::string one("hi\0there"),two("hi\0there",8);
std::cout << one << '\n' << two << std::endl;
prints
"hi"
"hi there"
::EDIT::
pFrom is almost certainly not a std::string, you will need to use strcpy, sorry. You do not need to embed a \0.
fancy way to do this using std::strings
Code:
{
std::string tmp = "C:\\Documents and Settings\\" + std::string(name) + "\\whatever.txt";
sfos.pName = new char[tmp.size()+1];
strcpy(sfos.pName,tmp.c_str());
}
note that if you had already done this, (assigned pFrom a result of new) you need to remember to delete [] first.