aPathToFile.SetName("");
aPathToFile.SetExtension("");
OSD_Directory aBaseDir(aPathToFile);
- if (!aBaseDir.Exists())
+ if (aPathToFile.TrekLength() != 0 && !aBaseDir.Exists())
aBaseDir.Build(OSD_Protection());
// save the document
aStatus = theApp->SaveAs(theDoc, theFilename);