Function CSPFile::Create()
Description:
Creates a new file overwriting any existing file with the same filename.
 |
Prototype:
bool Create(const CSPString& strFilename, unsigned long ulMode = FILE_WRITE);
Arguments:
- const CSPString& strFilename [IN]
The filename of the new file.
- unsigned long ulMode = FILE_WRITE [IN]
The read or write mode.
Return value:
If successful, it returns true. Otherwise, it returns false.
Remarks:
You can assign the value CSPFile::FILE_WRITE to argument ulMode, if you want to create and open a file for writing only, CSPFile::FILE_READ for reading only, or both using the bitwise OR for both reading and writing.
Examples:
CSPFile f;
f.Create( "C:\\somedir\\newfile.txt", CSPFile::FILE_WRITE );
See also:
member functions Open(), Close()
|
|