JCL Help:TJclTempFileStream.Create

From Project JEDI Wiki
Jump to navigationJump to search


Summary

Creates an instance of TJclTempFileStream.


Pascal

 public constructor Create(const Prefix: string);


Parameters

Parameters Description
const Prefix: string On input the first three characters of the string are used to form the name of the temporary file (can be empty). On return, assuming the function succeeded, the FileName property contains the actual name of the temporary file, including the path.


Description

Create creates a temporary file in the temporary folder as returned by GetTempPath. The file is created with read and write access and is deleted as soon as it is closed. The file cannot be opened by another call to CreateFile. The file is created with the temporary attribute which means the system will attempt to keep the file's data in memory rather than caching it. Therefore you should free the object as soon as possible using the Free destructor. The file is automatically deleted when the object is destroyed.


About

Donator

Marcel van Brakel


Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page