/* $DOC$ $NAME$ ft_SaveArr() $CATEGORY$ Array $ONELINER$ Save Clipper array to a disc file. $SYNTAX$ ft_SaveArr( , , ) -> lRet $ARGUMENTS$ is any Clipper array except those containing compiled code blocks. is a DOS file name. will return any DOS file error. All arguments are required. $RETURNS$ .F. if there was a DOS file error or the array contained code blocks, otherwise returns .T. $DESCRIPTION$ ft_SaveArr() saves any Clipper array, except those containing compiled code blocks, to a disc file. The array can be restored from the disc file using ft_RestArr(). [1992-10-01 Librarian note: This function does not appear to work with multi-dimensional arrays. If you'd care to modify it to support this feature, please do and send it to Glenn Scott 71620,1521.] $EXAMPLES$ aArray := { ; { "Invoice 1", hb_SToD( "19910415" ), 1234.32, .T. }, ; { "Invoice 2", Date(), 234.98, .F. }, ; { "Invoice 3", Date() + 1, 0, .T. } } nErrorCode := 0 ft_SaveArr( aArray, "invoice.dat", @nErrorCode ) IF nErrorCode == 0 aSave := ft_RestArr( "invoice.dat", @nErrorCode ) IF nErrorCode != 0 ? "Error restoring array" ENDIF ELSE ? "Error writing array" ENDIF $SEEALSO$ ft_RestArr() $END$ */ /* $DOC$ $NAME$ ft_RestArr() $CATEGORY$ Array $ONELINER$ Restore a Clipper array from a disc file $SYNTAX$ ft_RestArr( , ) -> aArray $ARGUMENTS$ is a DOS file name. will return any DOS file error. All arguments are required. $RETURNS$ Return an array variable. $DESCRIPTION$ ft_RestArr() restores an array which was saved to a disc file using ft_SaveArr(). [1992-10-01 Librarian note: This function does not appear to work with multi-dimensional arrays. If you'd care to modify it to support this feature, please do and send it to Glenn Scott 71620,1521.] $EXAMPLES$ aArray := { ; { "Invoice 1", hb_SToD( "19910415" ), 1234.32, .T. }, ; { "Invoice 2", Date(), 234.98, .F. }, ; { "Invoice 3", Date() + 1, 0, .T. } } nErrorCode := 0 ft_SaveArr( aArray, "invoice.dat", @nErrorCode ) IF nErrorCode == 0 aSave := ft_RestArr( "invoice.dat", @nErrorCode ) IF nErrorCode != 0 ? "Error restoring array" ENDIF ELSE ? "Error writing array" ENDIF $SEEALSO$ ft_SaveArr() $END$ */