FileCClose

FileCClose

Closes a file after backup mode

Syntax

      FileCClose() --> <lClosed>

Returns

<lClosed> : .T., when the the file that was opened with FileCopy() is successfully closed.

Description

FILE COPY CLOSE

After you copy on multiple disks, this function should be routinely called. This is to prevent the source file, previously designed with FileCopy(), from remaining open. For example, this may occur if you terminate the copy procedure.

Note

. Regardless of the share mode, all other users are not allowed access. This situation stays this way without needing a file handle.

Example

      Show a back up with FileCopy().  After terminating, close the source
      file:

      FileCopy(cSource, cTarget, .T.)      // Back up mode
      DO NEXTDISK                          // When terminated Terminated = .T.
      DO WHILE FileCOpen() .AND. .NOT. Terminated
         FileCCont(cTarget)                // Next disk, new name
         DO NEXTDISK                       // Request for disk exchange
      ENDDO
      IF Terminated
         FileCClose()                      // Close source file!
      ENDIF

Seealso

FileCopy(), FileCCont(), FileCOpen(), FileCDaTi()

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s