.. highlightlang:: us .. _fclose: fclose ====== .. index:: fclose .. us.tag fclose ENGLISH ffiles :ref:`fclose` closes a file. .. function:: bool = fclose(fh) .. us.return **Return Value** If the function succeeds, the return value is TRUE (1); otherwise it is FALSE (0). .. us.params **Parameters** .. uparam:: fh *fh* is a file handle created by calling the :ref:`fopen` function. .. us.example **Example** :: fh = fopen("/test.txt", "w"); a = rand(10,10); fprintf(fh, "%10.2f\r\n", a); fclose(fh); EdCreate("/test.txt"); .. seealso:: :ref:`overview-binary-and-text-files`, :ref:`fopen`, :ref:`fshow` :sub:`id-324305`