LabWindows/CVI

TDMS_CloseFile

int TDMS_CloseFile (TDMSFileHandle file);

Purpose

Closes a file handle. This function also closes all open channel group and channel handles for the specified file.

This function does not save the file before closing the file handle. Call TDMS_SaveFile to save the file.

Parameters

Input
Name Type Description
file TDMSFileHandle The handle of the file to be closed. You obtain this handle from the TDMS_OpenFileEx or TDMS_CreateFileEx function.

Return Value

Name Type Description
status int Return value indicating whether the function was successful. Unless otherwise stated, zero represents successful execution and a negative number represents the error code.

Error codes are defined in cvi\include\cvitdms.h.

Additional Information

Library: TDM Streaming Library

Include file: cvitdms.h

LabWindows/CVI compatibility: LabWindows/CVI 8.1 and later

© 2016 National Instruments. All rights reserved.

Examples

Refer to the following examples that use the TDMS_CloseFile function:

  • TDM Streaming\tdmsReader.cws

    Open example
  • TDM Streaming\tdmsWriteBenchmark.cws

    Open example
  • TDM Streaming\Advanced Read and Write\TDMS In Memory Write and Read\TDMS In Memory Write and Read.cws

    Open example