Hi guys,
I'm having a little problem setting a string value to another string..
I have the class:
class FILENAME
{
public:
string GetFullPath() const;
void SetFullPath(string& fname);
private:
string fullpath;
};
The declaration for the SetFullPath Method is:
void FILENAME::SetFullPath(string& fname)
{
fullpath = fname;
}
why is it that when I call the function with say,
else // it is a regular file, so push this onto our list
{
fname = path + "\\" + ffd.cFileName;
it->SetFullPath(fname);
it++;
}
and run it, it fails with an access violation..? =/
What am I doing wrong here?