You should use a temporary file whenever you need to store information temporarily for later retrieval. The one thing you must remember is to delete this temporary file before the application that created it is terminated. Skip to main content. C Cookbook by. Start your free trial. Thank you. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a uniquely named, zero-byte temporary file on disk and returns the full path of that file. This method creates a temporary file with a. TMP file extension. The temporary file is created within the user's temporary folder, which is the path returned by the GetTempPath method. Feedback will be sent to Microsoft: By pressing the submit button, your feedback will be used to improve Microsoft products and services.
Privacy policy. The GetTempFileName function generates a unique file name, and the GetTempPath function retrieves the path to a directory where temporary files should be created. The following procedure describes how an application creates a temporary file for data manipulation purposes.
Each of the previous steps is checked for success before moving to the next step, and a failure description is displayed if an error occurs.
The application will terminate immediately after displaying the error message.
0コメント