From f14c3433f065b43e7644a26fc67302a3451bf78c Mon Sep 17 00:00:00 2001 From: Luiz Rafael Culik Date: Fri, 28 Jan 2000 17:53:27 +0000 Subject: [PATCH] See Changelog 20000128 --- harbour/ChangeLog | 16 + harbour/doc/whatsnew.txt | 2 +- harbour/gt.b32 | 2 +- harbour/ngdoc/ft_helpc.prg | 155 ++- harbour/ngdoc/harbour.rsp | 37 +- harbour/source/rdd/dbcmd.c | 1826 +++++++++++++---------------- harbour/source/rtl/arrays.c | 488 ++++++-- harbour/source/rtl/objfunc.prg | 4 +- harbour/source/tools/fileread.prg | 2 +- harbour/source/tools/nconvert.prg | 102 +- harbour/source/tools/ng.prg | 13 +- harbour/source/tools/os2.prg | 5 +- harbour/source/tools/rtf.prg | 21 +- harbour/source/tools/troff.prg | 55 +- 14 files changed, 1469 insertions(+), 1259 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 0ae92def93..0cd897de20 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,3 +1,19 @@ +20000128-20:3 GMT+3 Luiz Rafael Culik + *source/rdd/dbcmd.c + *source/rtl/arrays.c + *Enhaced the Docs + *doc/whatnew.txt + *Description of the program that extract documention from source code forget the OS2 and TROFF output +20000115-20:3 GMT+3 Luiz Rafael Culik + + * ngdoc/ft_helpc.prg + * Fixed some erros + * source/tools/rtf.prg + * source/tools/ng.prg + * source/tools/os2.prg + * source/tools/troff.prg + * Fixed the aligment of text on generating the source files + 20000127-12:54 GMT+1 Patrick Mast * doc/whatsnew.txt * updated for build 31 diff --git a/harbour/doc/whatsnew.txt b/harbour/doc/whatsnew.txt index 2ca1206f87..240e9cd8a7 100644 --- a/harbour/doc/whatsnew.txt +++ b/harbour/doc/whatsnew.txt @@ -49,7 +49,7 @@ Build #31 2000-01-27 ISAFFIRM(), ISNEGATIVE(), NATIONMSG(), _NATSORTVER(), _NATMSGVER() - Added Harbour compiler tracing (i.e., debug output) - Many changes, fixes, and enhancements to documentation -- Program added to extract documentation from source code and create NG and HLP files +- Program added to extract documentation from source code and create NG,HLP ,OS2 IPF and TROFF output files - Compile time expression optimizer. - Some preprocessor fixes - Added ADS RDD diff --git a/harbour/gt.b32 b/harbour/gt.b32 index f1686fb542..e12198b6a1 100644 --- a/harbour/gt.b32 +++ b/harbour/gt.b32 @@ -58,4 +58,4 @@ troff.c : troff.prg harbour.exe .c.obj: bcc32 -c -O2 -Iinclude -o$@ $< - tlib lib\b32\hbgt.lib -+$@,, \ No newline at end of file + tlib lib\b32\hbgt.lib -+$@,, diff --git a/harbour/ngdoc/ft_helpc.prg b/harbour/ngdoc/ft_helpc.prg index afa70799aa..9e468532d8 100644 --- a/harbour/ngdoc/ft_helpc.prg +++ b/harbour/ngdoc/ft_helpc.prg @@ -45,7 +45,16 @@ * * 1/18/2000 Added Cleanup procedure when Generating Norton Guide * + * V1.05 + * 1/22/2000 Added Code to generate OS2 IPF files * + * V1.06 + * 1/25/2000 Fixed some error that was not generating a valid RTF File + * Removed Call TO HB_OEMTOANSI() on the rountines to generate the .Ngi + * and Rtf files. + * Added support to generate the Docs from .Txt files, See doc\Subcodes.txt + * for header file. + * */ /* @@ -136,6 +145,8 @@ STATIC cTest := DELIM + 'TESTS' + DELIM STATIC cStatus := DELIM + 'STATUS' + DELIM STATIC cPlat := DELIM + 'PLATFORMS' + DELIM STATIC cFiles := DELIM + 'FILES' + DELIM +STATIC cSubCode := DELIM + 'SUBCODE' + DELIM +STATIC cFunction := DELIM + 'FUNCTION' +DELIM STATIC theHandle *+±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±± @@ -144,10 +155,10 @@ STATIC theHandle *+ *+±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±± *+ -FUNCTION FT_HELPC( cFlags, cLinkName, cAtFile, cDir ) +FUNCTION FT_HELPC( cFlags, cLinkName, cAtFile ) // LOCAL variables: - LOCAL aExtensions := { "*.PRG", "*.C", "*.ASM", "*.CH" } + LOCAL aExtensions := { "*.PRG", "*.C", "*.ASM", "*.CH" , "*.TXT" } LOCAL i LOCAL j LOCAL nItem @@ -657,14 +668,17 @@ STATIC FUNCTION ProcessFiles // - // LOCAL variables: -#define D_NORMAL 1 -#define D_ARG 2 -#define D_SYNTAX 3 -#define D_IGNORE 4 -#define D_SEEALSO 5 -#define D_INCLUDE 6 -#define D_ONELINE 7 -#define D_STATUS 8 +#define D_NORMAL 1 +#define D_ARG 2 +#define D_SYNTAX 3 +#define D_IGNORE 4 +#define D_SEEALSO 5 +#define D_INCLUDE 6 +#define D_ONELINE 7 +#define D_STATUS 8 +#define D_TESTS 9 +#define D_FUNCTIONS 10 + LOCAL i LOCAL j LOCAL nFiles := LEN( aDirList ) @@ -782,7 +796,7 @@ STATIC FUNCTION ProcessFiles IF lDoc // 1) function name - IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 + IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 .OR. AT(cSubCode,cBuffer) > 0 cBuffer := ReadLN( @lEof ) nLineCnt ++ // Save the function name @@ -926,17 +940,7 @@ STATIC FUNCTION ProcessFiles nMode := D_NORMAL lAddBlank := .T. ELSEIF AT( cTest, cBuffer ) > 0 - - IF !lBlankLine - FWRITE( nWriteHandle, CRLF ) - ENDIF - FWRITE( nWriteHandle, ".par bold on" + CRLF ) - FWRITE( nWriteHandle, " Tests" + CRLF ) - FWRITE( nWriteHandle, ".endpar" + CRLF ) - - nMode := D_NORMAL - lAddBlank := .T. - + nMode=D_TESTS ELSEIF AT( cCompl, cBuffer ) > 0 IF !lBlankLine @@ -971,6 +975,18 @@ STATIC FUNCTION ProcessFiles nMode := D_NORMAL lAddBlank := .T. + ELSEIF AT( cFunction, cBuffer ) > 0 + + IF !lBlankLine + FWRITE( nWriteHandle, CRLF ) + ENDIF + FWRITE( nWriteHandle, ".par bold on" + CRLF ) + FWRITE( nWriteHandle, " Function" + CRLF ) + FWRITE( nWriteHandle, ".endpar" + CRLF ) + + nMode := D_NORMAL + lAddBlank := .T. + ELSEIF AT( cStatus, cBuffer ) > 0 nMode := D_STATUS ELSEIF AT( cSee, cBuffer ) > 0 @@ -1038,7 +1054,15 @@ STATIC FUNCTION ProcessFiles FWRITE( nWriteHandle, ".endpar" + CRLF ) ENDIF ProcStatus( nWriteHandle, StripNgControls( cBuffer ) ) + ELSEIF nMode=D_TESTS + IF !EMPTY(cBuffer) + FWRITE( nWriteHandle, ".par bold on" + CRLF ) + FWRITE( nWriteHandle, " Tests" + CRLF ) + FWRITE( nWriteHandle, ".endpar" + CRLF ) + FWRITE( nWriteHandle, CRLF ) + ENDIF + FWRITE( nWriteHandle,StripNgControls( cBuffer ) +CRLF) ELSE // unknown data from somewhere @@ -2233,7 +2257,8 @@ STATIC FUNCTION ProcessRtf // Now close down this little piece lDoc := .F. IF .NOT. EMPTY( cSeeAlso ) - oRtf:WritePar( "See Also" ):EndPar() + oRtf:WritePar(""):EndPar() + oRtf:WriteParBold( "See Also" ) ProcRtfalso( oRtf, cSeealso ) ENDIF @@ -2248,7 +2273,7 @@ STATIC FUNCTION ProcessRtf IF lDoc // 1) function name - IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 + IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 .OR. AT( cSubCode, cBuffer ) >0 cBuffer := ReadLN( @lEof ) nLineCnt ++ // Save the function name @@ -2330,7 +2355,7 @@ STATIC FUNCTION ProcessRtf // Now start writing out what we know oRtf:WriteTitle( PAD( cFuncName, 21 ), cFuncName ) oRtf:WriteParBold( cOneLine ) - oRtf:WritePar( HB_OEMTOANSI( cBar ) ):EndPar() + oRtf:WritePar( cBar ):EndPar() // 4) all other stuff ELSE @@ -2401,6 +2426,7 @@ STATIC FUNCTION ProcessRtf IF !lBlankLine oRtf:WritePar( "" ):EndPar() ENDIF + oRtf:WritePar( "" ):EndPar() oRtf:WriteParBold( " Compilance" ) nMode := D_NORMAL lAddBlank := .T. @@ -2422,6 +2448,16 @@ STATIC FUNCTION ProcessRtf nMode := D_NORMAL lAddBlank := .T. + ELSEIF AT( cFunction, cBuffer ) > 0 + + IF !lBlankLine + oRtf:WritePar( "" ):EndPar() + ENDIF + oRtf:WriteParBold( " Functions" ) + + nMode := D_NORMAL + lAddBlank := .T. + ELSEIF AT( cSee, cBuffer ) > 0 nMode := D_SEEALSO ELSEIF AT( cInc, cBuffer ) > 0 @@ -2445,6 +2481,8 @@ STATIC FUNCTION ProcessRtf /* nNonBlank:=FirstNB(cBuffer) cBuffer=STUFF(cBuffer,nNonBlank,0,"^a1f ")*/ oRtf:WritePar( cBuffer ):EndPar() + oRtf:WritePar(""):EndPar() + ELSEIF nMode = D_ARG IF LEN( cBuffer ) > LONGLINE write_error( "Arguments", cBuffer, nLineCnt, ; @@ -2469,6 +2507,7 @@ STATIC FUNCTION ProcessRtf lAddBlank := .F. ENDIF oRtf:WritePar( StripNgControls( cBuffer ) ):EndPar() + ELSEIF nMode = D_SEEALSO IF .NOT. EMPTY( cBuffer ) cSeeAlso := StripFiles( ALLTRIM( cBuffer ) ) @@ -2484,10 +2523,20 @@ STATIC FUNCTION ProcessRtf ENDIF ELSEIF nMode = D_STATUS IF !EMPTY( cBuffer ) + oRtf:WritePar(""):EndPar() oRtf:WriteParBold( "Status" ) + oRtf:WritePar(""):EndPar() + xaddblank:=.T. + ELSE + oRtf:WritePar(""):EndPar() + xAddBlank:=.T. ENDIF ProcStatusRtf( oRtf, cBuffer ) - + IF !xAddBlank + oRtf:WritePar(""):EndPar() + xaddblank:=.T. + ENDIF + xAddBlank:=.F. ELSE // unknown data from somewhere @@ -2507,7 +2556,7 @@ STATIC FUNCTION ProcessRtf NEXT RETURN NIL - + *+±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±± *+ *+ Function ProcRtfAlso() @@ -2585,8 +2634,9 @@ RETURN nil *+±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±± *+ FUNCTION ProcStatus( nWriteHandle, cBuffer ) - - IF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "R" + IF LEN( ALLTRIM( cBuffer ) ) > 1 + FWRITE( nWriteHandle, cBuffer + CRLF ) + ELSEIF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "R" FWRITE( nWriteHandle, " Ready" + CRLF ) ELSEIF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "S" FWRITE( nWriteHandle, " Started" + CRLF ) @@ -2602,8 +2652,9 @@ RETURN nil *+±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±± *+ FUNCTION ProcStatusRTF( nWriteHandle, cBuffer ) - - IF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "R" + IF LEN( ALLTRIM(cBuffer) ) >1 + nWriteHandle:WritePar( cBuffer ):EndPar() + ELSEIF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "R" nWriteHandle:WritePar( " Ready" ):EndPar() ELSEIF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "S" nWriteHandle:WritePar( " Started" ):EndPar() @@ -2756,7 +2807,7 @@ STATIC FUNCTION ProcessWww IF lDoc // 1) function name - IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 + IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 .OR. AT( cSubCode, cBuffer ) >0 cBuffer := ReadLN( @lEof ) nLineCnt ++ // Save the function name @@ -2928,6 +2979,15 @@ STATIC FUNCTION ProcessWww ENDIF oHtm:WriteParBold( " Files" ) + nMode := D_NORMAL + lAddBlank := .T. + ELSEIF AT( cFunction, cBuffer ) > 0 + + IF !lBlankLine + oHtm:WritePar( "" ) + ENDIF + oHtm:WriteParBold( " Functions" ) + nMode := D_NORMAL lAddBlank := .T. @@ -3116,8 +3176,9 @@ RETURN nil *+±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±± *+ FUNCTION ProcStatusWww( nWriteHandle, cBuffer ) - - IF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "R" + IF LEN( ALLTRIM( cBuffer ) ) >1 + nWriteHandle:WritePar( cBuffer) + ELSEIF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "R" nWriteHandle:WritePar( " Ready" ) ELSEIF SUBSTR( ALLTRIM( cBuffer ), 1 ) == "S" nWriteHandle:WritePar( " Started" ) @@ -3333,7 +3394,7 @@ STATIC FUNCTION ProcessNgi IF lDoc // 1) function name - IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 + IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 .OR. AT( cSubCode, cBuffer ) >0 cBuffer := ReadLN( @lEof ) nLineCnt ++ // Save the function name @@ -3415,7 +3476,7 @@ STATIC FUNCTION ProcessNgi // Now start writing out what we know oNgi:WriteTitle( PAD( cFuncName, 21 ) + cOneLine, cFuncName ) oNgi:WritePar( cOneLine ) - oNgi:WritePar( HB_OEMTOANSI( cBar ) ) + oNgi:WritePar( cBar ) // 4) all other stuff ELSE @@ -3507,6 +3568,15 @@ STATIC FUNCTION ProcessNgi nMode := D_NORMAL lAddBlank := .T. + ELSEIF AT( cFunction, cBuffer ) > 0 + + IF !lBlankLine + oNgi:WritePar( "" ) + ENDIF + oNgi:WriteParBold( " Functions" ) + + nMode := D_NORMAL + lAddBlank := .T. ELSEIF AT( cSee, cBuffer ) > 0 nMode := D_SEEALSO ELSEIF AT( cInc, cBuffer ) > 0 @@ -4009,7 +4079,7 @@ STATIC FUNCTION ProcessTroff IF lDoc // 1) function name - IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 + IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 .OR. AT( cSubCode, cBuffer ) >0 cBuffer := ReadLN( @lEof ) nLineCnt ++ // Save the function name @@ -4432,7 +4502,7 @@ STATIC FUNCTION ProcessOs2 IF lDoc // 1) function name - IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 + IF AT( cFunc, cBuffer ) > 0 .OR. AT( cComm, cBuffer ) > 0 .OR. AT( cSubCode, cBuffer ) >0 cBuffer := ReadLN( @lEof ) nLineCnt ++ // Save the function name @@ -4599,6 +4669,15 @@ STATIC FUNCTION ProcessOs2 ENDIF oOs2:WriteParBold( " Files" ) + nMode := D_NORMAL + lAddBlank := .T. + ELSEIF AT( cFunction, cBuffer ) > 0 + + IF !lBlankLine + oOs2:WritePar( "" ) + ENDIF + oOs2:WriteParBold( " Function" ) + nMode := D_NORMAL lAddBlank := .T. diff --git a/harbour/ngdoc/harbour.rsp b/harbour/ngdoc/harbour.rsp index 5e27be3d18..cd176daed3 100644 --- a/harbour/ngdoc/harbour.rsp +++ b/harbour/ngdoc/harbour.rsp @@ -47,6 +47,7 @@ source\rtl\memvarbl.prg source\rtl\memvars.c source\rtl\menuto.prg source\rtl\mlcount.c +source\rtl\mlpos.c source\rtl\mouseapi.c source\rtl\mousexxx.c source\rtl\msgxxx.c @@ -87,39 +88,3 @@ source\rtl\wait.prg source\rtl\word.c source\rtl\xhelp.c source\rtl\xsavescr.prg -source\tools\asciisum.c -source\tools\ascpos.c -source\tools\atdiff.c -source\tools\chareven.c -source\tools\charmix.c -source\tools\charodd.c -source\tools\chrcount.c -source\tools\chrfirst.c -source\tools\chrtotal.c -source\tools\ctchksum.c -source\tools\ctchrmix.c -source\tools\ctcrypt.c -source\tools\dates2.c -source\tools\datesx.c -source\tools\fileread.prg -source\tools\hb_f.c -source\tools\html.prg -source\tools\io.c -source\tools\mathx.c -source\tools\nconvert.prg -source\tools\numtxten.prg -source\tools\numtxthu.prg -source\tools\rtf.prg -source\tools\ng.prg -source\tools\strasint.c -source\tools\strcount.c -source\tools\strcspn.c -source\tools\strdiff.c -source\tools\strexpan.c -source\tools\strfmt.c -source\tools\stringp.prg -source\tools\stringsx.c -source\tools\strleft.c -source\tools\strpbrk.c -source\tools\strright.c - diff --git a/harbour/source/rdd/dbcmd.c b/harbour/source/rdd/dbcmd.c index ad6f8bea97..9823f3a7bf 100644 --- a/harbour/source/rdd/dbcmd.c +++ b/harbour/source/rdd/dbcmd.c @@ -2036,65 +2036,44 @@ HARBOUR HB_DBCLOSEAREA( void ) } /* $DOC$ * $FUNCNAME$ - * DBCOMMIT() + * DBCOMMIT() * $CATEGORY$ - * DATA BASE + * DATA BASE * $ONELINER$ - * Flush pending updates + * Updates all index and database buffers for a given workarea * $SYNTAX$ * DBCOMMIT() --> NIL * $ARGUMENTS$ * * $RETURNS$ - * DBCOMMIT() always returns NIL. + * DBCOMMIT() always returns NIL. * $DESCRIPTION$ - * DBCOMMIT() causes all updates to the current work area to be written to - * disk. All updated database and index buffers are written to DOS and a - * DOS COMMIT request is issued for the database (.dbf) file and any index - * files associated with the work area. - * - * DBCOMMIT() performs the same function as the standard COMMIT command - * except that it operates only on the current work area. For more - * information, refer to the COMMIT command. - * - * Notes - * - * Network environment: DBCOMMIT() makes database updates visible - * to other processes. To insure data integrity, issue DBCOMMIT() - * before an UNLOCK operation. For more information, refer to the - * Network Programming chapter in the Programming and Utilities guide. - * - * DBCOMMIT() uses DOS interrupt 21h function 68h to perform the - * solid-disk write. It is up to the network operating system to - * properly implement this request. Check with the network vendor to - * see if this is supported. - * + * This function updates all of the information for a give,selected, + * or active workarea.This operation includes all database and index + * buffers for that work area only. This function does not update all + * open work areas. * $EXAMPLES$ - * In this example, COMMIT is used to force a write to disk after - * a series of memory variables are assigned to field variables: - * - * USE Sales EXCLUSIVE NEW - * MEMVAR->Name := Sales->Name - * MEMVAR->Amount := Sales->Amount + * FUNCTION Main() + * LOCAL cName:=SPACE(40) + * LOCAL nId:=0 + * USE Test EXCLUSIVE NEW * // - * @ 10, 10 GET MEMVAR->Name - * @ 11, 10 GET MEMVAR->Amount + * @ 10, 10 GET cName + * @ 11, 10 GET nId * READ * // * IF UPDATED() * APPEND BLANK - * REPLACE Sales->Name WITH MEMVAR->Name - * REPLACE Sales->Amount WITH MEMVAR->Amount - * Sales->( DBCOMMIT() ) + * REPLACE Tests->Name WITH cName + * REPLACE Tests->Id WITH nId + * Tests->( DBCOMMIT() ) * ENDIF - * + * RETURN NIL * $TESTS$ * * $STATUS$ * R * $COMPLIANCE$ - * - * * $SEEALSO$ * DBCLOSEALL(),DBCOMMITALL(),DBUNLOCK() * $INCLUDE$ @@ -2115,7 +2094,7 @@ HARBOUR HB_DBCOMMIT( void ) * $CATEGORY$ * DATA BASE * $ONELINER$ - * Flush pending updates in all work areas + * Flushes the memory buffer and performs a hard-disk write * $SYNTAX$ * DBCOMMIT() --> NIL * $ARGUMENTS$ @@ -2123,53 +2102,35 @@ HARBOUR HB_DBCOMMIT( void ) * $RETURNS$ * DBCOMMIT() always returns NIL. * $DESCRIPTION$ - * DBCOMMITALL() causes all pending updates to all work areas to be written - * to disk. It is equivalent to calling DBCOMMIT() for every occupied work - * area. - * For more information, refer to DBCOMMIT(). - * Notes - * DBCOMMITALL() uses DOS interrupt 21h function 68h to perform - * the solid-disk write. It is up to the network operating system to - * properly implement this request. Check with the network vendor to - * see if this is supported. - * + * This function performs a hard-disk write for all work areas. + * Before the disk write is performed,all buffers are flushed. + * open work areas. * $EXAMPLES$ - - * The following example writes all pending updates to disk: - - * cLast := "Winston" + * FUNCTION Main() + * LOCAL cName:=SPACE(40) + * LOCAL nId:=0 + * USE Test EXCLUSIVE NEW + * USE TestId New INDEX Testid * // - * DBUSEAREA( .T., "DBFNTX", "Sales", "Sales", .T. ) - * DBSETINDEX( "SALEFNAM" ) - * DBSETINDEX( "SALELNAM" ) + * @ 10, 10 GET cName + * @ 11, 10 GET nId + * READ * // - * DBUSEAREA( .T., "DBFNTX", "Colls", "Colls", .T. ) - * DBSETINDEX( "COLLFNAM" ) - * DBSETINDEX( "COLLLNAM" ) - - * DBSELECTAREA( "Sales" ) // select "Sales" work area - - * IF ( Sales->(DBSEEK(cLast)) ) - * IF Sales->( DELETED() ) .AND. Sales( RLOCK() ) - * Sales->( DBRECALL() ) - * ? "Deleted record has been recalled." + * IF UPDATED() + * APPEND BLANK + * REPLACE Tests->Name WITH cName + * REPLACE Tests->Id WITH nId + * IF !TestId->(DBSEEK(nId)) + * APPEND BLANK + * REPLACE Tests->Id WITH nId * ENDIF - * ELSE - * ? "Not found" * ENDIF - * // - * // processing done, write updates to disk and close * DBCOMMITALL() - * DBCLOSEALL() - * QUIT - * + * RETURN NIL * $TESTS$ - * * $STATUS$ * R * $COMPLIANCE$ - * - * $SEEALSO$ * DBCLOSEALL(),DBCOMMIT(),DBUNLOCK() * $INCLUDE$ @@ -2191,7 +2152,7 @@ HARBOUR HB_DBCOMMITALL( void ) /* $DOC$ * $FUNCNAME$ - * __DBCONTINUE + * __DBCONTINUE() * $CATEGORY$ * DATA BASE * $ONELINER$ @@ -2213,9 +2174,9 @@ HARBOUR HB_DBCOMMITALL( void ) * Each work area may have an active LOCATE condition. In CA-Clipper, a * LOCATE condition remains pending until a new LOCATE condition is * specified. No other commands release the condition. - - Notes - + * + * Notes + * * Scope and WHILE condition: Note that the scope and WHILE * condition of the initial LOCATE are ignored; only the FOR condition * is used with CONTINUE. If you are using a LOCATE with a WHILE @@ -2688,7 +2649,7 @@ HARBOUR HB_DBCREATE( void ) * $CATEGORY$ * DATA BASE * $ONELINER$ - * Mark a record for deletion + * Marks records for deletion in a database. * $SYNTAX$ * DBDELETE() --> NIL * $ARGUMENTS$ @@ -2696,52 +2657,25 @@ HARBOUR HB_DBCREATE( void ) * $RETURNS$ * DBDELETE() always returns NIL. * $DESCRIPTION$ - DBDELETE() marks the current record as deleted. Records marked for - deletion can be filtered using SET DELETED or removed from the file - using the PACK command. - - DBDELETE() performs the same function as the standard DELETE command - with a scope of the current record. For more information, refer to the - DELETE command. - - Notes - - Logical records: If the global _SET_DELETED status is true - (.T.), deleted records are not logically visible. That is, database - operations which operate on logical records will not consider records - marked for deletion. Note, however, that if _SET_DELETED is true - (.T.) when the current record is marked for deletion, the record - remains visible until it is no longer the current record. - - Network environment: For a shared database on a network, - DBDELETE() requires the current record to be locked. For more - information, refer to the Network Programming chapter of the - Programming and Utilities guide. - * + * This function marks a record for deletion in the selected + * or aliased work area.If the DELETED setting is on, the record + * will still be visible until the record pointer in that work area + * is moved to another record. + * In a networking situation, this function requires that the record + * be locked prior to issuing the DBDELETE() function. * $EXAMPLES$ - The following example deletes a record after a successful - record lock: - - cLast := "Winston" - DBUSEAREA( .T., "DBFNTX", "Sales", "Sales", .T. ) - DBSETINDEX( "LASTNAME" ) - // - IF ( Sales->(DBSEEK(cLast)) ) - IF Sales->( RLOCK() ) - Sales->( DBDELETE() ) - ? "Record deleted: ", Sales( DELETED() ) - ELSE - ? "Unable to lock record..." - ENDIF - ELSE - ? "Not found" - ENDIF + * nId:=10 + * USE TestId INDEX TestId NEW + * IF TestId->(DBSEEK(nId)) + * IF TestId->(RLOCK()) + * DBDELETE() + * ENDIF + * ENDIF + * USE * $TESTS$ - * * $STATUS$ * R - * $COMPLIANCE$ - * + * $COMPLIANCE$ * $SEEALSO$ * DBRECALL() * $INCLUDE$ @@ -2758,78 +2692,34 @@ HARBOUR HB_DBDELETE( void ) } /* $DOC$ * $FUNCNAME$ - * DBFILTER() + * DBFILTER() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the current filter expression as a character string + * Return the filter expression in a work area * $SYNTAX$ - * DBFILTER() --> cFilter + * DBFILTER() --> cFilter * $ARGUMENTS$ * * $RETURNS$ - * DBFILTER() returns the filter condition defined in the current work area - * as a character string. If no FILTER has been SET, DBFILTER() returns a - * null string (""). - * + * DBFILTER() returns the filter expression. * $DESCRIPTION$ - * DBFILTER() is a database function used to save and reexecute an active - * filter by returning the filter expression as a character string that can - * be later recompiled and executed using the macro operator (&). This - * function operates like the DBRELATION() and DBRSELECT() functions which - * save and reexecute the linking expression of a relation within a work - * area. - * - * Since each work area can have an active filter, DBFILTER() can return - * the filter expression of any work area. This is done by referring to - * DBFILTER() within an aliased expression as demonstrated below. - * - * Notes - * - * Declared variables: A character string returned by DBFILTER() - * may not operate correctly when recompiled and executed using the - * macro operator (&) if the original filter expression contained - * references to local or static variables, or otherwise depended on - * compile-time declarations. - * + * This function return the expression of the SET FILTER TO command + * for the current or designated work area. If no filter condition + * is present,a NULL string will be returned. * $EXAMPLES$ - * This example opens two database files, sets two filters, then - * displays the filter expressions for both work areas: - * - * USE Customer INDEX Customer NEW - * SET FILTER TO Last = "Smith" - * USE Invoices INDEX Invoices NEW - * SET FILTER TO CustId = "Smi001" - * SELECT Customer + * USE Test INDEX Test NEW + * SET FILTER TO Name= "Harbour" + * USE TestId INDEX TestId NEW + * SET FILTER TO Id = 1 + * SELECT Test * // - * ? DBFILTER() // Result: Last = "Smith" - * ? Invoices->(DBFILTER()) // Result: Custid = "Smi001" - * - * This user-defined function, CreateQry(), uses DBFILTER() to - * create a memory file containing the current filter expression in the - * private variable cFilter: - * - * FUNCTION CreateQry( cQryName ) - * - * PRIVATE cFilter := DBFILTER() - * SAVE ALL LIKE cFilter TO (cQryName + ".qwy") - * RETURN NIL - * - * You can later RESTORE a query file with this user-defined - * function, SetFilter(): - * - * FUNCTION SetFilter() - * PARAMETER cQryName - * RESTORE FROM &cQryName..qwy ADDITIVE - * SET FILTER TO &cFilter. - * RETURN NIL - * + * ? DBFILTER() + * ? TestId->(DBFILTER()) * $TESTS$ - * * $STATUS$ * R * $COMPLIANCE$ - * * $SEEALSO$ * DBRELATION(),DBRSELECT() * $INCLUDE$ @@ -2853,65 +2743,36 @@ HARBOUR HB_DBFILTER( void ) } /* $DOC$ * $FUNCNAME$ - * DBGOBOTTOM() + * DBGOBOTTOM() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Move to the last logical record + * Moves the record pointer to the bottom of the database. * $SYNTAX$ - * DBGOBOTTOM() --> NIL + * DBGOBOTTOM() --> NIL * $ARGUMENTS$ * * $RETURNS$ - * DBGOBOTTOM() always returns NIL. + * DBGOBOTTOM() always returns NIL. * $DESCRIPTION$ - * DBGOBOTTOM() moves to last logical record in the current work area. - * - * DBGOBOTTOM() performs the same function as the standard GO BOTTOM - * command. For more information, refer to the GO command. - * - * Notes - * - * Logical records: DBGOBOTTOM() operates on logical records. If - * there is an active index, DBGOBOTTOM() moves to the last record in - * indexed order. If a filter is set, only records which meet the - * filter condition are considered. - * - * Controlling order: If more than one index is active in the - * work area, the operation is performed using the controlling order as - * set by DBSETORDER() or the SET ORDER command. For more information, - * refer to the SET ORDER command. - * - * Network environment: For a shared file on a network, moving to - * a different record may cause updates to the current record to become - * visible to other processes. - * + * This function moves the record pointer in the selected or aliased + * work area to the end of the file.The position of the record pointer + * is affected by the values in the index key or by an active FILTER + * condition.Otherwise,if no index is active or if no filter condition + * is present,the value of the record pointer will be LASTREC(). * $EXAMPLES$ - * The following example uses DBGOBOTTOM() to position the record - * pointer on the last logical record: - * - * cLast := "Winston" - * DBUSEAREA( .T., "DBFNTX", "Sales", "Sales", .T. ) - * DBSETINDEX( "LASTNAME" ) - * // - * Sales->( DBGOBOTTOM() ) - * IF ( Sales->Last == "Winston" ) - * IF RLOCK() - * Sales->( DBDELETE() ) - * ? "Record deleted: ", Sales( DELETED() ) - * ELSE - * ? "Unable to lock record..." - * ENDIF - * END - * + * USE Tests + * DBGOTOP() + * ? RECNO() + * DBGOBOTTOM() + * ? RECNO() + * USE * $TESTS$ - * * $STATUS$ - * R + * R * $COMPLIANCE$ - * * $SEEALSO$ - * BOF(),EOF(),DBSKIP(),DBSEEK(),DBGOTOP() + * BOF(),EOF(),DBSKIP(),DBSEEK(),DBGOTOP() * $INCLUDE$ * * $END$ @@ -2926,40 +2787,31 @@ HARBOUR HB_DBGOBOTTOM( void ) } /* $DOC$ * $FUNCNAME$ - * DBGOTO() + * DBGOTO() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Move to the record having the specified record number + * Position the record pointer to a specific location. * $SYNTAX$ - * DBGOTO() --> NIL + * DBGOTO() --> NIL * $ARGUMENTS$ - * is a numeric value that specifies the record number - * of the desired record. - * + * Record number or unique identity * $RETURNS$ - * DBGOTO() always returns NIL. + * DBGOTO() always returns NIL. * $DESCRIPTION$ - * DBGOTO() moves to the record whose record number is equal to - * . If no such record exists, the work area is positioned - * to LASTREC() + 1 and both EOF() and BOF() return true (.T.). - * - * DBGOTO() performs the same function as the standard GO command. For - * more information, refer to the GO command. - * - * Notes - * - * Logical records: DBGOTO() does not respect logical visibility. - * That is, if the specified record exists, it will become the current - * record regardless of any index or filter condition. - * - * Network environment: For a shared file on a network, moving to - * a different record may cause updates to the current record to become - * visible to other processes. - * + * This function places the record pointer,if working with a .DBF file, + * in selected or aliased work area at the record number specified by + * .The position if not affected by an active index or + * by any enviromental SET condiction. + * Issuing a DBGOTO(RECNO()) call in a network enviroment will refresh + * the database and index buffers.This is the same as a DBSKIP(0) call. + * The parameter may be something other than a record + * number.In some data formats, for example, the value of + * is a unique primary key while in other formats, could + * be an array offset if the data set was an array. * $EXAMPLES$ * - * The following example uses DBGOTO() to iteratively process + * The following example uses DBGOTO() to iteratively process * every fourth record: * * DBUSEAREA( .T., "DBFNTX", "Sales", "Sales", .T. ) @@ -3001,58 +2853,35 @@ HARBOUR HB_DBGOTO( void ) } /* $DOC$ * $FUNCNAME$ - * DBGOTOP() + * DBGOTOP() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Move to the first logical record + * Moves the record pointer to the bottom of the database. * $SYNTAX$ - * DBGOTOP() --> NIL + * DBGOTOP() --> NIL * $ARGUMENTS$ * * $RETURNS$ - * DBGOTOP() always returns NIL. - * $DESCRIPTION$ - * DBGOTOP() moves to last logical record in the current work area. - * - * DBGOTOP() performs the same function as the standard GO TOP - * command. For more information, refer to the GO command. - * - * Notes - * - * Logical records: DBGOTOP() operates on logical records. If - * there is an active index, DBGOTOP() moves to the last record in - * indexed order. If a filter is set, only records which meet the - * filter condition are considered. - * - * Controlling order: If more than one index is active in the - * work area, the operation is performed using the controlling order as - * set by DBSETORDER() or the SET ORDER command. For more information, - * refer to the SET ORDER command. - * - * Network environment: For a shared file on a network, moving to - * a different record may cause updates to the current record to become - * visible to other processes. - * + * DBGOTOP() always returns NIL. + * This function moves the record pointer in the selected or aliased + * work area to the top of the file.The position of the record pointer + * is affected by the values in the index key or by an active FILTER + * condition.Otherwise,if no index is active or if no filter condition + * is present,the value of RECNO() will be 1. * $EXAMPLES$ - * - * This example demonstrates the typical use of DBGOTOP(): - * + * USE Tests * DBGOTOP() - * WHILE ( !EOF() ) - * ? FIELD->Name - * DBSKIP() - * END - * - * + * ? RECNO() + * DBGOBOTTOM() + * ? RECNO() + * USE * $TESTS$ - * * $STATUS$ - * R + * R * $COMPLIANCE$ - * * $SEEALSO$ - * BOF(),EOF(),DBSKIP(),DBSEEK(),DBGOBOTTOM() + * BOF(),EOF(),DBSKIP(),DBSEEK(),DBGOBOTTOM() * $INCLUDE$ * * $END$ @@ -3303,67 +3132,40 @@ HARBOUR HB___DBPACK( void ) } /* $DOC$ * $FUNCNAME$ - * DBRECALL() + * DBRECALL() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Reinstate a record marked for deletion + * Recalls a record previousy marked for deletion. * $SYNTAX$ - * DBRECALL() --> NIL + * DBRECALL() --> NIL * $ARGUMENTS$ - * + * * $RETURNS$ - * DBRECALL() always returns NIL. + * DBRECALL() always returns NIL. * $DESCRIPTION$ - * DBRECALL() causes the current record to be reinstated if it is marked - * for deletion. - * - * DBRECALL() performs the same function as the RECALL command. For more - * information, refer to the DELETE and RECALL commands. - * - * Notes - * - * Logical records: Reinstating a deleted record affects the - * record's logical visibility if the global _SET_DELETED status is true - * (.T.). For more information, refer to the DBDELETE() function and - * the DELETE and RECALL commands. - * - * Network environment: For a shared database on a network, - * DBRECALL() requires the current record to be locked. - * + * This function unmarks those records marked for deletion nd reactivates + * them in the aliased or selected work area.If a record is DELETED and + * the DELETED setting is on, the record will still be visible for a + * DBRECALL() provided that the database record pointer has not been + * skipped.Once a record marked for deletion with the DELETE setting ON + * has been skipped, it no longer canbe brought back with DBRECALL(). * $EXAMPLES$ - * - * The following example recalls a record if it is deleted and - * attempts to lock the record if successful: - * - * cLast := "Winston" - * DBUSEAREA( .T., "DBFNTX", "Sales", "Sales", .T. ) - * DBSETINDEX( "LASTNAME" ) - * // - * IF ( Sales->(DBSEEK(cLast)) ) - * IF Sales->( DELETED() ) - * - * IF Sales( RLOCK() ) - * Sales( DBRECALL() ) - * ? "Record recalled" - * ELSE - * ? "Unable to lock record..." - * ENDIF - * ENDIF - * ELSE - * ? "Not found" - * ENDIF - * + * USE Test NEW + * DBGOTO(10) + * DBDELETE() + * ? DELETED() + * DBRECALL() + * ? DELETED() + * USE * $TESTS$ - * * $STATUS$ - * R + * R * $COMPLIANCE$ - * * $SEEALSO$ - * DBDELETE() + * DBDELETE() * $INCLUDE$ - * + * * $END$ */ @@ -3376,35 +3178,35 @@ HARBOUR HB_DBRECALL( void ) } /* $DOC$ * $FUNCNAME$ - * DBRLOCK() + * DBRLOCK() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Lock the record at the current or specified identity + * Lock the record at the current or specified identity * $SYNTAX$ - * DBRLOCK([]) --> lSuccess + * DBRLOCK([]) --> lSuccess * $ARGUMENTS$ - * is a unique value guaranteed by the structure of the - * data file to reference a specific item in a data source (database). In - * a (.dbf) is the record number. In other data formats, - * is the unique primary key value. - * + * is a unique value guaranteed by the structure of the + * data file to reference a specific item in a data source (database). In + * a (.dbf) is the record number. In other data formats, + * is the unique primary key value. + * * $RETURNS$ * - * DBRLOCK() returns lSuccess, a logical data type that is true (.T.) if - * successful, false (.F.) if unsuccessful. + * DBRLOCK() returns lSuccess, a logical data type that is true (.T.) if + * successful, false (.F.) if unsuccessful. * * $DESCRIPTION$ - * DBRLOCK() is a database function that locks the record identified by the - * value . In Xbase, is the record number. + * DBRLOCK() is a database function that locks the record identified by the + * value . In Xbase, is the record number. * - * If you do not specify , all record locks are released and the - * current record is locked. If you specify , DBRLOCK() - * attempts to lock it and, if successful, adds it to the locked record - * list. - * + * If you do not specify , all record locks are released and the + * current record is locked. If you specify , DBRLOCK() + * attempts to lock it and, if successful, adds it to the locked record + * list. + * * $EXAMPLES$ - * This example shows two different methods for locking multiple + * This example shows two different methods for locking multiple * records: * * FUNCTION dbRLockRange( nLo, nHi ) @@ -3433,13 +3235,13 @@ HARBOUR HB_DBRECALL( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBUNLOCK(),DBUNLOCKALL(),FLOCK(),RLOCK() + * DBUNLOCK(),DBUNLOCKALL(),FLOCK(),RLOCK() * $INCLUDE$ - * + * * $END$ */ @@ -3461,25 +3263,25 @@ HARBOUR HB_DBRLOCK( void ) } /* $DOC$ * $FUNCNAME$ - * DBRLOCKLIST() + * DBRLOCKLIST() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return an array of the current Lock List + * Return an array of the current Lock List * $SYNTAX$ - * DBRLOCKLIST() --> aRecordLocks + * DBRLOCKLIST() --> aRecordLocks * $ARGUMENTS$ * * $RETURNS$ - * Returns an array of the locked records in the current or aliased work - * area. + * Returns an array of the locked records in the current or aliased work + * area. * $DESCRIPTION$ - * DBRLOCKLIST() is a database function that returns a one-dimensional - * array that contains the identities of record locks active in the - * selected work area. - * + * DBRLOCKLIST() is a database function that returns a one-dimensional + * array that contains the identities of record locks active in the + * selected work area. + * * $EXAMPLES$ - * PROCEDURE PrintCurLocks() + * PROCEDURE PrintCurLocks() * * LOCAL aList * LOCAL nSize @@ -3500,13 +3302,13 @@ HARBOUR HB_DBRLOCK( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * RLOCK(),DBRLOCK(),DBRUNLOCK() + * RLOCK(),DBRLOCK(),DBRUNLOCK() * $INCLUDE$ - * + * * $END$ */ @@ -3525,27 +3327,27 @@ HARBOUR HB_DBRLOCKLIST( void ) } /* $DOC$ * $FUNCNAME$ - * DBRUNLOCK() + * DBRUNLOCK() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Release all or specified record locks + * Release all or specified record locks * $SYNTAX$ - * DBRUNLOCK([]) --> NIL + * DBRUNLOCK([]) --> NIL * $ARGUMENTS$ - * is a unique value guaranteed by the structure of the + * is a unique value guaranteed by the structure of the * data file to reference a specific item in a data source (database). In * a (.dbf) is the record number. In other data formats, * is the unique primary key value. * $RETURNS$ - * DBRUNLOCK() always returns NIL. + * DBRUNLOCK() always returns NIL. * $DESCRIPTION$ - * DBRUNLOCK() is a database function that releases the lock on + * DBRUNLOCK() is a database function that releases the lock on * and removes it from the Lock List. If is not specified, all * record locks are released. - * + * * $EXAMPLES$ - * PROCEDURE dbRUnlockRange( nLo, nHi ) + * PROCEDURE dbRUnlockRange( nLo, nHi ) * * LOCAL nCounter * @@ -3559,13 +3361,13 @@ HARBOUR HB_DBRLOCKLIST( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ * RLOCK(),DBRLOCK(),DBRLOCKLIST() * $INCLUDE$ - * + * * $END$ */ @@ -3578,29 +3380,29 @@ HARBOUR HB_DBRUNLOCK( void ) } /* $DOC$ * $FUNCNAME$ - * DBSEEK() + * DBSEEK() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Move to the record having the specified key value + * Move to the record having the specified key value * $SYNTAX$ - * DBSEEK(, [],[]) --> lFound + * DBSEEK(, [],[]) --> lFound * $ARGUMENTS$ - * is a value of any type that specifies the key value + * is a value of any type that specifies the key value * associated with the desired record. * - * is an optional logical value that specifies whether a + * is an optional logical value that specifies whether a * soft seek is to be performed. This determines how the work area is * positioned if the specified key value is not found (see below). If * is omitted, the current global _SET_SOFTSEEK setting is * used. - * is an optional logical value that set the current + * is an optional logical value that set the current * record position to the last record if successful * $RETURNS$ - * DBSEEK() returns true (.T.) if the specified key value was found; + * DBSEEK() returns true (.T.) if the specified key value was found; * otherwise, it returns false (.F.). * $DESCRIPTION$ - * DBSEEK() moves to the first logical record whose key value is equal to + * DBSEEK() moves to the first logical record whose key value is equal to * . If such a record is found, it becomes the current record and * DBSEEK() returns true (.T.). Otherwise, DBSEEK() returns false (.F.) * and the positioning of the work area is as follows: for a normal (not @@ -3610,29 +3412,29 @@ HARBOUR HB_DBRUNLOCK( void ) * If no such record exists, the work area is positioned to LASTREC() + 1 * and EOF() returns true (.T.). * - * For a work area with no active indexes, DBSEEK() has no effect. + * For a work area with no active indexes, DBSEEK() has no effect. * - * DBSEEK() performs the same function as the standard SEEK command. For + * DBSEEK() performs the same function as the standard SEEK command. For * more information, refer to the SEEK command. * * Notes * - * Logical records: DBSEEK() operates on logical records. + * Logical records: DBSEEK() operates on logical records. * Records are considered in indexed order. If a filter is set, only * records which meet the filter condition are considered. * - * Controlling order: If the work area has more than one active + * Controlling order: If the work area has more than one active * index, the operation is performed using the controlling order as set * by DBSETORDER() or the SET ORDER command. For more information, * refer to the SET ORDER command. * - * Network environment: For a shared file on a network, moving to + * Network environment: For a shared file on a network, moving to * a different record may cause updates to the current record to become * visible to other processes. * - * + * * $EXAMPLES$ - * In this example, DBSEEK() moves the pointer to the record in + * In this example, DBSEEK() moves the pointer to the record in * the database, Employee, in which the value in FIELD “cName” matches * the entered value of cName: * @@ -3646,13 +3448,13 @@ HARBOUR HB_DBRUNLOCK( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ - * DBSEEK() is Compatible with CA-Clipper 5.3 + * DBSEEK() is Compatible with CA-Clipper 5.3 * $SEEALSO$ - * DBGOBOTTOM(),DBGOTOP(),DBSKIP(),EOF(),BOF(),FOUND() + * DBGOBOTTOM(),DBGOTOP(),DBSKIP(),EOF(),BOF(),FOUND() * $INCLUDE$ - * + * * $END$ */ @@ -3683,25 +3485,25 @@ HARBOUR HB_DBSEEK( void ) } /* $DOC$ * $FUNCNAME$ - * DBSELECTAREA() + * DBSELECTAREA() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Change the current work area + * Change the current work area * $SYNTAX$ - * DBSELECTAREA( | ) --> NIL + * DBSELECTAREA( | ) --> NIL * $ARGUMENTS$ - * is a numeric value between zero and 250, inclusive, that + * is a numeric value between zero and 250, inclusive, that * specifies the work area being selected. * - * is a character value that specifies the alias of a + * is a character value that specifies the alias of a * currently occupied work area being selected. - * + * * $RETURNS$ - * DBSELECTAREA() always returns NIL. + * DBSELECTAREA() always returns NIL. * $DESCRIPTION$ * - * DBSELECTAREA() causes the specified work area to become the current work + * DBSELECTAREA() causes the specified work area to become the current work * area. All subsequent database operations will apply to this work area * unless another work area is explicitly specified for an operation. * DBSELECTAREA() performs the same function as the standard SELECT @@ -3709,16 +3511,16 @@ HARBOUR HB_DBSEEK( void ) * * Notes * - * Selecting zero: Selecting work area zero causes the lowest + * Selecting zero: Selecting work area zero causes the lowest * numbered unoccupied work area to become the current work area. * - * Aliased expressions: The alias operator (->) can temporarily + * Aliased expressions: The alias operator (->) can temporarily * select a work area while an expression is evaluated and automatically * restore the previously selected work area afterward. For more * information, refer to the alias operator (->). * * $EXAMPLES$ - * The following example selects a work area via the alias name: + * The following example selects a work area via the alias name: * * cLast := "Winston" * DBUSEAREA( .T., "DBFNTX", "Sales", "Sales", .T. ) @@ -3743,13 +3545,13 @@ HARBOUR HB_DBSEEK( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBUSEAREA(),SELECT() + * DBUSEAREA(),SELECT() * $INCLUDE$ - * + * * $END$ */ @@ -3802,27 +3604,27 @@ HARBOUR HB_DBSELECTAREA( void ) } /* $DOC$ * $FUNCNAME$ - * DBSETDRIVER() + * DBSETDRIVER() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the default database driver and optionally set a new driver + * Return the default database driver and optionally set a new driver * $SYNTAX$ - * DBSETDRIVER([]) --> cCurrentDriver + * DBSETDRIVER([]) --> cCurrentDriver * $ARGUMENTS$ - * is an optional character value that specifies the name of + * is an optional character value that specifies the name of * the database driver that should be used to activate and manage new work * areas when no driver is explicitly specified. * $RETURNS$ - * DBSETDRIVER() returns the name of the current default driver. + * DBSETDRIVER() returns the name of the current default driver. * $DESCRIPTION$ - * DBSETDRIVER() sets the database driver to be used when activating new + * DBSETDRIVER() sets the database driver to be used when activating new * work areas without specifying a driver. If the specified driver is not * available to the application, the call has no effect. DBSETDRIVER() * returns the name of the current default driver, if any. - * + * * $EXAMPLES$ - * This example makes the "DBFNDX" driver the default driver. If + * This example makes the "DBFNDX" driver the default driver. If * the driver is unavailable, a message is issued: * DBSETDRIVER("DBFNDX") * IF ( DBSETDRIVER() <> "DBFNDX" ) @@ -3832,13 +3634,13 @@ HARBOUR HB_DBSELECTAREA( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBUSEAREA() + * DBUSEAREA() * $INCLUDE$ - * + * * $END$ */ @@ -3878,47 +3680,47 @@ HARBOUR HB___DBSETFOUND( void ) } /* $DOC$ * $FUNCNAME$ - * DBSKIP() + * DBSKIP() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Move relative to the current record + * Move relative to the current record * $SYNTAX$ - * DBSKIP([]) --> NIL + * DBSKIP([]) --> NIL * $ARGUMENTS$ - * is the number of logical records to move, relative to the + * is the number of logical records to move, relative to the * current record. A positive value means to skip forward, and a negative * value means to skip backward. If is omitted, a value of 1 is * assumed. * $RETURNS$ - * DBSKIP() always returns NIL. + * DBSKIP() always returns NIL. * $DESCRIPTION$ - * DBSKIP() moves either forward or backward relative to the current + * DBSKIP() moves either forward or backward relative to the current * record. Attempting to skip forward beyond the last record positions the * work area to LASTREC() + 1 and EOF() returns true (.T.). Attempting to * skip backward beyond the first record positions the work area to the * first record and BOF() returns true (.T.). - * DBSKIP() performs the same function as the standard SKIP command. For + * DBSKIP() performs the same function as the standard SKIP command. For * more information, refer to the SKIP command. * * Notes * - * Logical records: DBSKIP() operates on logical records. If + * Logical records: DBSKIP() operates on logical records. If * there is an active index, records are considered in indexed order. * If a filter is set, only records which meet the filter condition are * considered. * - * Controlling order: If the work area has more than one active + * Controlling order: If the work area has more than one active * index, the skip operation is performed using the controlling order as * set by DBSETORDER() or the SET ORDER command. For more information, * refer to the SET ORDER command. * - * Network environment: For a shared file on a network, moving to + * Network environment: For a shared file on a network, moving to * a different record may cause updates to the current record to become * visible to other processes. * * $EXAMPLES$ - * This example demonstrates a typical use of the DBSKIP() + * This example demonstrates a typical use of the DBSKIP() * function: * * DBGOTOP() @@ -3930,13 +3732,13 @@ HARBOUR HB___DBSETFOUND( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ * BOF(),DBGOBOTTOM(),DBGOTOP(),DBSEEK(),EOF() * $INCLUDE$ - * + * * $END$ */ @@ -3955,47 +3757,47 @@ HARBOUR HB_DBSKIP( void ) } /* $DOC$ * $FUNCNAME$ - * DBSETFILTER() + * DBSETFILTER() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Set a filter condition + * Set a filter condition * $SYNTAX$ - * DBSETFILTER(, []) --> NIL + * DBSETFILTER(, []) --> NIL * $ARGUMENTS$ - * is a code block that expresses the filter condition in + * is a code block that expresses the filter condition in * executable form. - * is an optional character value that expresses the + * is an optional character value that expresses the * filter condition in textual form. If is omitted, the * DBSETFILTER() function will return an empty string for the work area. - * + * * $RETURNS$ - * DBSETFILTER() always returns NIL. + * DBSETFILTER() always returns NIL. * $DESCRIPTION$ - * DBSETFILTER() sets a logical filter condition for the current work area. + * DBSETFILTER() sets a logical filter condition for the current work area. * When a filter is set, records which do not meet the filter condition are * not logically visible. That is, database operations which act on * logical records will not consider these records. - * The filter expression supplied to DBSETFILTER() evaluates to true (.T.) + * The filter expression supplied to DBSETFILTER() evaluates to true (.T.) * if the current record meets the filter condition; otherwise, it should * evaluate to false (.F.). - * The filter expression may be a code block () or both a code + * The filter expression may be a code block () or both a code * block and equivalent text (). If both versions are * supplied, they must express the same condition. If the text version is * omitted, DBFILTER() will return an empty string for the work area. - * DBSETFILTER() performs the same function as the standard SET FILTER + * DBSETFILTER() performs the same function as the standard SET FILTER * command. For more information, refer to the SET FILTER command. * - * Notes + * Notes * - * Logical records: DBSETFILTER() affects the logical visibility + * Logical records: DBSETFILTER() affects the logical visibility * of records (see above). * - * Side effects: Setting a filter condition is only guaranteed to + * Side effects: Setting a filter condition is only guaranteed to * restrict visibility of certain records as described above. The * filter expression is not necessarily evaluated at any particular * time, by any particular means, or on any particular record or series @@ -4005,13 +3807,13 @@ HARBOUR HB_DBSKIP( void ) * moving to a different record or changing the contents of a record), * the effect is unpredictable. * - * Evaluation context: When the filter expression is evaluated, + * Evaluation context: When the filter expression is evaluated, * the associated work area is automatically selected as the current * work area before the evaluation; the previously selected work area is * automatically restored afterward. * $EXAMPLES$ - * This example limits data access to records in which the Age + * This example limits data access to records in which the Age * field value is less than 40: * * USE Employee NEW @@ -4021,13 +3823,13 @@ HARBOUR HB_DBSKIP( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBFILTER(),DBCLEARFILTER() + * DBFILTER(),DBCLEARFILTER() * $INCLUDE$ - * + * * $END$ */ @@ -4057,36 +3859,36 @@ HARBOUR HB_DBSETFILTER( void ) } /* $DOC$ * $FUNCNAME$ - * DBSTRUCT() + * DBSTRUCT() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Create an array containing the structure of a database file + * Create an array containing the structure of a database file * $SYNTAX$ - * DBSTRUCT() --> aStruct + * DBSTRUCT() --> aStruct * $ARGUMENTS$ - * + * * $RETURNS$ - * DBSTRUCT() returns the structure of the current database file in an + * DBSTRUCT() returns the structure of the current database file in an * array whose length is equal to the number of fields in the database * file. Each element of the array is a subarray containing information * for one field. The subarrays have the following format: - * DBSTRUCT() Return Array - * ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ - * Position * Metasymbol * Dbstruct.ch - * ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ - * 1 * * cName * * DBS_NAME - * 2 * * cType * * DBS_TYPE - * 3 * * nLength * DBS_LEN - * 4 * * nDecimals * DBS_DEC - * ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ + * DBSTRUCT() Return Array + * ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ + * Position * Metasymbol * Dbstruct.ch + * ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ + * 1 * * cName * * DBS_NAME + * 2 * * cType * * DBS_TYPE + * 3 * * nLength * DBS_LEN + * 4 * * nDecimals * DBS_DEC + * ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ - * If there is no database file in USE in the current work area, DBSTRUCT() + * If there is no database file in USE in the current work area, DBSTRUCT() * returns an empty array ({}). - * + * * $DESCRIPTION$ - * DBSTRUCT() is a database function that operates like COPY STRUCTURE + * DBSTRUCT() is a database function that operates like COPY STRUCTURE * EXTENDED by creating an array of structure information rather than a * database file of structure information. There is another function, * DBCREATE(), that can create a database file from the structure array. @@ -4095,11 +3897,11 @@ HARBOUR HB_DBSETFILTER( void ) * will operate on an unselected work area if you specify it as part of an * aliased expression as shown below. - * Note, a header file, Dbstruct.ch, located in \HARBOUR\INCLUDE contains + * Note, a header file, Dbstruct.ch, located in \HARBOUR\INCLUDE contains * a series of manifest constants for each field attribute. - * + * * $EXAMPLES$ - * This example opens two database files then creates an array + * This example opens two database files then creates an array * containing the database structure using DBSTRUCT() within an aliased * expression. The field names are then listed using AEVAL(): @@ -4115,13 +3917,13 @@ HARBOUR HB_DBSETFILTER( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * AFIELDS() + * AFIELDS() * $INCLUDE$ - * DbStruct.ch + * DbStruct.ch * $END$ */ @@ -4207,32 +4009,32 @@ HARBOUR HB_DBTABLEEXT( void ) } /* $DOC$ * $FUNCNAME$ - * DBUNLOCK() + * DBUNLOCK() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Release all locks for the current work area + * Release all locks for the current work area * $SYNTAX$ - * DBUNLOCK() --> NIL + * DBUNLOCK() --> NIL * $ARGUMENTS$ - * + * * $RETURNS$ - * DBUNLOCK() always returns NIL. + * DBUNLOCK() always returns NIL. * $DESCRIPTION$ - * DBUNLOCK() releases any record or file locks obtained by the current + * DBUNLOCK() releases any record or file locks obtained by the current * process for the current work area. DBUNLOCK() is only meaningful on a * shared database in a network environment. - * DBUNLOCK() performs the same function as the standard UNLOCK command. + * DBUNLOCK() performs the same function as the standard UNLOCK command. * For more information, refer to the UNLOCK command. * Notes - * Network environment: Releasing locks may cause updates to the + * Network environment: Releasing locks may cause updates to the * database to become visible to other processes. - * + * * $EXAMPLES$ - * The following example illustrates a basic use of the + * The following example illustrates a basic use of the * DBUNLOCK() function: * cLast := "Winston" @@ -4254,13 +4056,13 @@ HARBOUR HB_DBTABLEEXT( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ * DBUNLOCKALL(),FLOCK(),RLOCK() * $INCLUDE$ - * + * * $END$ */ @@ -4273,28 +4075,28 @@ HARBOUR HB_DBUNLOCK( void ) } /* $DOC$ * $FUNCNAME$ - * DBUNLOCKALL() + * DBUNLOCKALL() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Release all locks for all work areas + * Release all locks for all work areas * $SYNTAX$ - * DBUNLOCKALL() --> NIL + * DBUNLOCKALL() --> NIL * $ARGUMENTS$ - * + * * $RETURNS$ - * DBUNLOCKALL() always returns NIL. + * DBUNLOCKALL() always returns NIL. * $DESCRIPTION$ - * DBUNLOCKALL() releases any record or file locks obtained by the current + * DBUNLOCKALL() releases any record or file locks obtained by the current * process for any work area. DBUNLOCKALL() is only meaningful on a shared * database in a network environment. It is equivalent to calling * DBUNLOCK() on every occupied work area. - * DBUNLOCKALL() performs the same function as the UNLOCK ALL command. For + * DBUNLOCKALL() performs the same function as the UNLOCK ALL command. For * more information, refer to the UNLOCK ALL command. - * + * * $EXAMPLES$ - * The following example marks a record for deletion if an + * The following example marks a record for deletion if an * RLOCK() attempt is successful, then clears all locks in all work * areas: @@ -4325,13 +4127,13 @@ HARBOUR HB_DBUNLOCK( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBUNLOCK(),FLOCK(),RLOCK() + * DBUNLOCK(),FLOCK(),RLOCK() * $INCLUDE$ - * + * * $END$ */ @@ -4348,38 +4150,38 @@ HARBOUR HB_DBUNLOCKALL( void ) } /* $DOC$ * $FUNCNAME$ - * DBUSEAREA() + * DBUSEAREA() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Use a database file in a work area + * Use a database file in a work area * $SYNTAX$ - * DBUSEAREA( [], [], , [], + * DBUSEAREA( [], [], , [], * [], []) --> NIL * $ARGUMENTS$ - * is an optional logical value. A value of true (.T.) + * is an optional logical value. A value of true (.T.) * selects the lowest numbered unoccupied work area as the current work * area before the use operation. If is false (.F.) or omitted, * the current work area is used; if the work area is occupied, it is * closed first. - * is an optional character value. If present, it specifies + * is an optional character value. If present, it specifies * the name of the database driver which will service the work area. If * is omitted, the current default driver is used (see note * below). - * specifies the name of the database (.dbf) file to be opened. + * specifies the name of the database (.dbf) file to be opened. - * is an optional character value. If present, it specifies + * is an optional character value. If present, it specifies * the alias to be associated with the work area. The alias must * constitute a valid HARBOUR identifier. A valid may be any * legal identifier (i.e., it must begin with an alphabetic character and * may contain numeric or alphabetic characters and the underscore). * Within a single application, HARBOUR will not accept duplicate * aliases. If is omitted, a default alias is constructed from - * . + * . - * is an optional logical value. If present, it specifies + * is an optional logical value. If present, it specifies * whether the database (.dbf) file should be accessible to other processes * on a network. A value of true (.T.) specifies that other processes * should be allowed access; a value of false (.F.) specifies that the @@ -4387,45 +4189,45 @@ HARBOUR HB_DBUNLOCKALL( void ) * the current global _SET_EXCLUSIVE setting determines whether shared * access is allowed. - * is an optional logical value that specifies whether + * is an optional logical value that specifies whether * updates to the work area are prohibited. A value of true (.T.) * prohibits updates; a value of false (.F.) permits updates. A value of * true (.T.) also permits read-only access to the specified database * (.dbf) file. If is omitted, the default value is false * (.F.). * $RETURNS$ - * DBUSEAREA() always returns NIL. + * DBUSEAREA() always returns NIL. * $DESCRIPTION$ - * DBUSEAREA() associates the specified database (.dbf) file with the + * DBUSEAREA() associates the specified database (.dbf) file with the * current work area. - * DBUSEAREA() performs the same function as the standard USE command. For + * DBUSEAREA() performs the same function as the standard USE command. For * more information, refer to the USE command. - * Notes + * Notes - * Current driver: If no driver is specified in the call to + * Current driver: If no driver is specified in the call to * DBUSEAREA() the default driver is used. If more than one driver is * available to the application, the default driver is the driver * specified in the most recent call to DBSETDRIVER(). If DBSETDRIVER() * has not been called, the name of the default driver is undetermined. - * + * * $EXAMPLES$ - * This example is a typical use of the DBUSEAREA() function: + * This example is a typical use of the DBUSEAREA() function: * DBUSEAREA(.T., "DBFNDX", "Employees") * * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ * DBCLOSEAREA(),DBSETDRIVER(),SELECT(),SET() - * + * * $INCLUDE$ - * + * * $END$ */ @@ -4625,19 +4427,19 @@ HARBOUR HB_DBUSEAREA( void ) } /* $DOC$ * $FUNCNAME$ - * __DBZAP() + * __DBZAP() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Remove all records from the current database file + * Remove all records from the current database file * $SYNTAX$ - * __DbZap() -> NIL + * __DbZap() -> NIL * $ARGUMENTS$ - * + * * $RETURNS$ - * __DbZap() will always return nil + * __DbZap() will always return nil * $DESCRIPTION$ - * __DbZap*( is a database command that permanently removes all records from + * __DbZap*( is a database command that permanently removes all records from * files open in the current work area. This includes the current database * file, index files, and associated memo file. Disk space previously * occupied by the ZAPped files is released to the operating system. @@ -4646,9 +4448,9 @@ HARBOUR HB_DBUSEAREA( void ) * * To ZAP in a network environment, the current database file must be USEd * EXCLUSIVEly. - * + * * $EXAMPLES$ - * This example demonstrates a typical ZAP operation in a network + * This example demonstrates a typical ZAP operation in a network * environment: * * USE Sales EXCLUSIVE NEW @@ -4663,30 +4465,30 @@ HARBOUR HB_DBUSEAREA( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * + * * $INCLUDE$ - * + * * $END$ */ /* $DOC$ * $COMMANDNAME$ - * ZAP + * ZAP * $CATEGORY$ - * Command + * Command * $ONELINER$ - * Remove all records from the current database file + * Remove all records from the current database file * $SYNTAX$ - * ZAP + * ZAP * $ARGUMENTS$ - * + * * $RETURNS$ * * $DESCRIPTION$ - * ZAP is a database command that permanently removes all records from + * ZAP is a database command that permanently removes all records from * files open in the current work area. This includes the current database * file, index files, and associated memo file. Disk space previously * occupied by the ZAPped files is released to the operating system. ZAP @@ -4695,9 +4497,9 @@ HARBOUR HB_DBUSEAREA( void ) * * To ZAP in a network environment, the current database file must be USEd * EXCLUSIVEly. - * + * * $EXAMPLES$ - * This example demonstrates a typical ZAP operation in a network + * This example demonstrates a typical ZAP operation in a network * environment: * * USE Sales EXCLUSIVE NEW @@ -4712,13 +4514,13 @@ HARBOUR HB_DBUSEAREA( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * + * * $INCLUDE$ - * + * * $END$ */ @@ -4731,36 +4533,36 @@ HARBOUR HB___DBZAP( void ) } /* $DOC$ * $FUNCNAME$ - * DELETED() + * DELETED() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the deleted status of the current record + * Return the deleted status of the current record * $SYNTAX$ - * DELETED() --> lDeleted + * DELETED() --> lDeleted * $ARGUMENTS$ - * + * * $RETURNS$ - * DELETED() returns true (.T.) if the current record is marked for + * DELETED() returns true (.T.) if the current record is marked for * deletion; otherwise, it returns false (.F.). If there is no database * file in USE in the current work area, DELETED() returns false (.F.). * $DESCRIPTION$ - * DELETED() is a database function that determines if the current record + * DELETED() is a database function that determines if the current record * in the active work area is marked for deletion. Since each work area * with an open database file can have a current record, each work area has * its own DELETED() value. - * By default, DELETED() operates on the currently selected work area. It + * By default, DELETED() operates on the currently selected work area. It * will operate on an unselected work area if you specify it as part of an * aliased expression (see example below). - * In applications, DELETED() is generally used to query the deleted status + * In applications, DELETED() is generally used to query the deleted status * as a part of record processing conditions, or to display the deleted * status as a part of screens and reports. * $EXAMPLES$ - * This example uses DELETED() in the current and in an + * This example uses DELETED() in the current and in an * unselected work area: * USE Customer NEW @@ -4771,7 +4573,7 @@ HARBOUR HB___DBZAP( void ) * ? DELETED() // Result: .T. * ? Customer->(DELETED()) // Result: .F. - * This example uses DELETED() to display a record's deleted + * This example uses DELETED() to display a record's deleted * status in screens and reports: * @ 1, 65 SAY IF(DELETED(), "Inactive", "Active") @@ -4779,13 +4581,13 @@ HARBOUR HB___DBZAP( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * + * * $INCLUDE$ - * + * * $END$ */ @@ -4800,7 +4602,7 @@ HARBOUR HB_DELETED( void ) /* $DOC$ * $FUNCNAME$ - * EOF() + * EOF() * $CATEGORY$ * DATA BASE * $ONELINER$ @@ -4819,32 +4621,32 @@ HARBOUR HB_DELETED( void ) * $DESCRIPTION$ - * EOF() is a database function used to test for an end of file boundary + * EOF() is a database function used to test for an end of file boundary * condition when the record pointer is moving forward through a database * file. Any command that can move the record pointer can set EOF(). - * The most typical application is as a part of the argument + * The most typical application is as a part of the argument * of a DO WHILE construct that sequentially processes records in a * database file. Here would include a test for .NOT. EOF(), * forcing the DO WHILE loop to terminate when EOF() returns true (.T.). - * EOF() and FOUND() are often used interchangeably to test whether a SEEK, + * EOF() and FOUND() are often used interchangeably to test whether a SEEK, * FIND, or LOCATE command failed. With these commands, however, FOUND() * is preferred. - * When EOF() returns true (.T.), the record pointer is positioned at + * When EOF() returns true (.T.), the record pointer is positioned at * LASTREC() + 1 regardless of whether there is an active SET FILTER or SET * DELETED is ON. Further attempts to move the record pointer forward * return the same result without error. Once EOF() is set to true (.T.), * it retains its value until there is another attempt to move the record * pointer. - * By default, EOF() operates on the currently selected work area. It can + * By default, EOF() operates on the currently selected work area. It can * be made to operate on an unselected work area by specifying it within an * aliased expression (see example below). * $EXAMPLES$ - * This example demonstrates EOF() by deliberately moving the + * This example demonstrates EOF() by deliberately moving the * record pointer beyond the last record: * USE Sales @@ -4853,7 +4655,7 @@ HARBOUR HB_DELETED( void ) * SKIP * ? EOF() // Result: .T. - * This example uses aliased expressions to query the value of + * This example uses aliased expressions to query the value of * EOF() in unselected work areas: * USE Sales NEW @@ -4861,7 +4663,7 @@ HARBOUR HB_DELETED( void ) * ? Sales->(EOF()) * ? Customer->(EOF()) - * This example illustrates how EOF() can be used as part of a + * This example illustrates how EOF() can be used as part of a * condition for sequential database file operations: * USE Sales INDEX CustNum NEW @@ -4896,29 +4698,29 @@ HARBOUR HB_EOF( void ) } /* $DOC$ * $FUNCNAME$ - * FCOUNT() + * FCOUNT() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the number of fields in the current (.dbf) file + * Return the number of fields in the current (.dbf) file * $SYNTAX$ - * FCOUNT() --> nFields + * FCOUNT() --> nFields * $ARGUMENTS$ - * + * * $RETURNS$ - * FCOUNT() returns the number of fields in the database file in the + * FCOUNT() returns the number of fields in the database file in the * current work area as an integer numeric value. If there is no database * file open, FCOUNT() returns zero. * $DESCRIPTION$ - * FCOUNT() is a database function. It is useful in applications + * FCOUNT() is a database function. It is useful in applications * containing data-independent programs that can operate on any database * file. These include generalized import/export and reporting programs. * Typically, you use FCOUNT() to establish the upper limit of a FOR...NEXT * or DO WHILE loop that processes a single field at a time. - * By default, FCOUNT() operates on the currently selected work area. + * By default, FCOUNT() operates on the currently selected work area. * $EXAMPLES$ - * This example illustrates FCOUNT(), returning the number of + * This example illustrates FCOUNT(), returning the number of * fields in the current and an unselected work area: * USE Sales NEW @@ -4926,13 +4728,13 @@ HARBOUR HB_EOF( void ) * ? FCOUNT() // Result: 5 * ? Sales->(FCOUNT()) // Result: 8 - * This example uses FCOUNT() to DECLARE an array with field + * This example uses FCOUNT() to DECLARE an array with field * information: * LOCAL aFields := ARRAY(FCOUNT()) * AFIELDS(aFields) - * This example uses FCOUNT() as the upper boundary of a FOR loop + * This example uses FCOUNT() as the upper boundary of a FOR loop * that processes the list of current work area fields: * LOCAL nField @@ -4944,13 +4746,13 @@ HARBOUR HB_EOF( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ * FIELDNAME(),TYPE() * $INCLUDE$ - * + * * $END$ */ @@ -4964,28 +4766,28 @@ HARBOUR HB_FCOUNT( void ) } /* $DOC$ * $FUNCNAME$ - * FIELDGET() + * FIELDGET() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Retrieve the value of a field variable + * Retrieve the value of a field variable * $SYNTAX$ - * FIELDGET() --> ValueField + * FIELDGET() --> ValueField * $ARGUMENTS$ * is the ordinal position of the field in the record * structure for the current work area. * $RETURNS$ - * FIELDGET() returns the value of the specified field. If does + * FIELDGET() returns the value of the specified field. If does * not correspond to the position of any field in the current database * file, FIELDGET() returns NIL. * $DESCRIPTION$ - * FIELDGET() is a database function that retrieves the value of a field + * FIELDGET() is a database function that retrieves the value of a field * using its position within the database file structure rather than its * field name. Within generic database service functions this allows, * among other things, the retrieval of field values without use of the * macro operator. * $EXAMPLES$ - * This example compares FIELDGET() to functionally equivalent + * This example compares FIELDGET() to functionally equivalent * code that uses the macro operator to retrieve the value of a field: * LOCAL nField := 1, FName, FVal @@ -4999,13 +4801,13 @@ HARBOUR HB_FCOUNT( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * FIELDPUT() + * FIELDPUT() * $INCLUDE$ - * + * * $END$ */ @@ -5025,41 +4827,41 @@ HARBOUR HB_FIELDGET( void ) } /* $DOC$ * $FUNCNAME$ - * FIELDNAME() + * FIELDNAME() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return a field name from the current (.dbf) file + * Return a field name from the current (.dbf) file * $SYNTAX$ - * FIELDNAME/FIELD() --> cFieldName + * FIELDNAME/FIELD() --> cFieldName * $ARGUMENTS$ - * is the position of a field in the database file + * is the position of a field in the database file * structure. * $RETURNS$ - * FIELDNAME() returns the name of the specified field as a character + * FIELDNAME() returns the name of the specified field as a character * string. If does not correspond to an existing field in the * current database file or if no database file is open in the current work * area, FIELDNAME() returns a null string (""). * $DESCRIPTION$ - * FIELDNAME() is a database function that returns a field name using an + * FIELDNAME() is a database function that returns a field name using an * index to the position of the field name in the database structure. Use * it in data-independent applications where the field name is unknown. If * information for more than one field is required, use AFIELDS() to create * an array of field information or COPY STRUCTURE EXTENDED to create a * database of field information. - * If you need additional database file structure information, use TYPE() + * If you need additional database file structure information, use TYPE() * and LEN(). To obtain the number of decimal places for a numeric field, * use the following expression: * LEN(SUBSTR(STR(), RAT(".", ; * STR()) + 1)) - * By default, FIELDNAME() operates on the currently selected work area as + * By default, FIELDNAME() operates on the currently selected work area as * shown in the example below. - * + * * $EXAMPLES$ - * These examples illustrate FIELDNAME() used with several other + * These examples illustrate FIELDNAME() used with several other * functions: * USE Sales @@ -5068,7 +4870,7 @@ HARBOUR HB_FIELDGET( void ) * ? LEN(FIELDNAME(0)) // Result: 0 * ? LEN(FIELDNAME(40)) // Result: 0 - * This example uses FIELDNAME() to list the name and type of + * This example uses FIELDNAME() to list the name and type of * each field in Customer.dbf: * USE Customer NEW @@ -5077,7 +4879,7 @@ HARBOUR HB_FIELDGET( void ) * VALTYPE(&(FIELDNAME(nField))) * NEXT - * This example accesses fields in unselected work areas using + * This example accesses fields in unselected work areas using * aliased expressions: * USE Sales NEW @@ -5090,14 +4892,14 @@ HARBOUR HB_FIELDGET( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBSTRUCT() FCOUNT() LEN() misc.ngo:VALTYPE() - * + * DBSTRUCT(),FCOUNT(),LEN(),VALTYPE() + * * $INCLUDE$ - * + * * $END$ */ @@ -5126,38 +4928,38 @@ HARBOUR HB_FIELDNAME( void ) } /* $DOC$ * $FUNCNAME$ - * FIELDPOS() + * FIELDPOS() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the position of a field in a work area + * Return the position of a field in a work area * $SYNTAX$ - * FIELDPOS() --> nFieldPos + * FIELDPOS() --> nFieldPos * $ARGUMENTS$ - * is the name of a field in the current or specified work + * is the name of a field in the current or specified work * area. * $RETURNS$ - * FIELDPOS() returns the position of the specified field within the list + * FIELDPOS() returns the position of the specified field within the list * of fields associated with the current or specified work area. If the * current work area has no field with the specified name, FIELDPOS() * returns zero. * $DESCRIPTION$ - * FIELDPOS() is a database function that is the inverse of the FIELDNAME() + * FIELDPOS() is a database function that is the inverse of the FIELDNAME() * function. FIELDPOS() is most often used with the FIELDPUT() and * FIELDGET() functions. - * FIELDPOS() return the names of fields in any unselected work area by + * FIELDPOS() return the names of fields in any unselected work area by * referring to the function using an aliased expression. See the example * below. * $EXAMPLES$ - * This example demonstrates a typical specification of the + * This example demonstrates a typical specification of the * FIELDPOS() function: * USE Customer NEW * ? FIELDPOS("Name") * * * * // Result: 1 * ? FIELDGET(FIELDPOS("Name")) * * // Result: Kate - * This example uses FIELDPOS() to return the position of a + * This example uses FIELDPOS() to return the position of a * specified field in a unselected work area: * USE Customer NEW @@ -5167,13 +4969,13 @@ HARBOUR HB_FIELDNAME( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * FIELDGET(),FIELDPUT() + * FIELDGET(),FIELDPUT() * $INCLUDE$ - * + * * $END$ */ @@ -5204,33 +5006,33 @@ HARBOUR HB_FIELDPOS( void ) } /* $DOC$ * $FUNCNAME$ - * FIELDPUT() + * FIELDPUT() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Set the value of a field variable + * Set the value of a field variable * $SYNTAX$ - * FIELDPUT(, ) --> ValueAssigned + * FIELDPUT(, ) --> ValueAssigned * $ARGUMENTS$ * is the ordinal position of the field in the current * database file. - * is the value to assign to the given field. The data + * is the value to assign to the given field. The data * type of this expression must match the data type of the designated field * variable. * $RETURNS$ - * FIELDPUT() returns the value assigned to the designated field. If + * FIELDPUT() returns the value assigned to the designated field. If * does not correspond to the position of any field in the current * database file, FIELDPUT() returns NIL. * $DESCRIPTION$ - * FIELDPUT() is a database function that assigns to the field + * FIELDPUT() is a database function that assigns to the field * at ordinal position in the current work area. This function * allows you to set the value of a field using its position within the * database file structure rather than its field name. Within generic * database service functions this allows, among other things, the setting * of field values without use of the macro operator. * $EXAMPLES$ - * This example compares FIELDPUT() to functionally equivalent + * This example compares FIELDPUT() to functionally equivalent * code that uses the macro operator to set the value of a field: * // Using macro operator @@ -5241,13 +5043,13 @@ HARBOUR HB_FIELDPOS( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * FIELDGET() + * FIELDGET() * $INCLUDE$ - * + * * $END$ */ @@ -5270,28 +5072,28 @@ HARBOUR HB_FIELDPUT( void ) } /* $DOC$ * $FUNCNAME$ - * FLOCK() + * FLOCK() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Lock an open and shared database file + * Lock an open and shared database file * $SYNTAX$ - * FLOCK() --> lSuccess + * FLOCK() --> lSuccess * $ARGUMENTS$ - * + * * $RETURNS$ - * FLOCK() returns true (.T.) if an attempt to lock a database file in USE + * FLOCK() returns true (.T.) if an attempt to lock a database file in USE * in the current work area succeeds; otherwise, it returns false (.F.). * For more information on file locking, refer to the Network Programming * chapter in the Programming and Utilities guide. - * + * * $DESCRIPTION$ - * FLOCK() is a database function used in network environments to lock an + * FLOCK() is a database function used in network environments to lock an * open and shared database file, preventing other users from updating the * file until the lock is released. Records in the locked file are * accessible for read-only operations. * - * FLOCK() is related to USE...EXCLUSIVE and RLOCK(). USE...EXCLUSIVE + * FLOCK() is related to USE...EXCLUSIVE and RLOCK(). USE...EXCLUSIVE * opens a database file so that no other user can open the same file at * the same time and is the most restrictive locking mechanism in * HARBOUR. RLOCK() is the least restrictive and attempts to place an @@ -5314,23 +5116,23 @@ HARBOUR HB_FIELDPUT( void ) * UPDATE ON FLOCK() or USE...EXCLUSIVE * ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ * - * For each invocation of FLOCK(), there is one attempt to lock the + * For each invocation of FLOCK(), there is one attempt to lock the * database file, and the result is returned as a logical value. A file * lock fails if another user currently has a file or record lock for the * same database file or EXCLUSIVE USE of the database file. If FLOCK() is * successful, the file lock remains in place until you UNLOCK, CLOSE the * DATABASE, or RLOCK(). * - * By default, FLOCK() operates on the currently selected work area as + * By default, FLOCK() operates on the currently selected work area as * shown in the example below. * - * Notes + * Notes * - * SET RELATION: HARBOUR does not automatically lock all work + * SET RELATION: HARBOUR does not automatically lock all work * areas in the relation chain when you lock the current work area, and * an UNLOCK has no effect on related work areas. * $EXAMPLES$ - * This example uses FLOCK() for a batch update of prices in + * This example uses FLOCK() for a batch update of prices in * Inventory.dbf: * * USE Inventory NEW @@ -5341,7 +5143,7 @@ HARBOUR HB_FIELDPUT( void ) * ? "File not available" * ENDIF * - * This example uses an aliased expression to attempt a file lock + * This example uses an aliased expression to attempt a file lock * in an unselected work area: * * USE Sales NEW @@ -5353,13 +5155,13 @@ HARBOUR HB_FIELDPUT( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * RLOCK() + * RLOCK() * $INCLUDE$ - * + * * $END$ */ @@ -5381,47 +5183,47 @@ HARBOUR HB_FLOCK( void ) } /* $DOC$ * $FUNCNAME$ - * FOUND() + * FOUND() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Determine if the previous search operation succeeded + * Determine if the previous search operation succeeded * $SYNTAX$ - * FOUND() --> lSuccess + * FOUND() --> lSuccess * $ARGUMENTS$ - * + * * $RETURNS$ - * FOUND() returns true (.T.) if the last search command was successful; + * FOUND() returns true (.T.) if the last search command was successful; * otherwise, it returns false (.F.). - * + * * $DESCRIPTION$ - * FOUND() is a database function that determines whether a search + * FOUND() is a database function that determines whether a search * operation (i.e., FIND, LOCATE, CONTINUE, SEEK, or SET RELATION) * succeeded. When any of these commands are executed, FOUND() is set to * true (.T.) if there is a match; otherwise, it is set to false (.F.). * - * If the search command is LOCATE or CONTINUE, a match is the next record + * If the search command is LOCATE or CONTINUE, a match is the next record * meeting the scope and condition. If the search command is FIND, SEEK or * SET RELATION, a match is the first key in the controlling index that * equals the search argument. If the key value equals the search * argument, FOUND() is true (.T.); otherwise, it is false (.F.). * - * The value of FOUND() is retained until another record movement command + * The value of FOUND() is retained until another record movement command * is executed. Unless the command is another search command, FOUND() is * automatically set to false (.F.). * - * Each work area has a FOUND() value. This means that if one work area + * Each work area has a FOUND() value. This means that if one work area * has a RELATION set to a child work area, querying FOUND() in the child * returns true (.T.) if there is a match. * - * By default, FOUND() operates on the currently selected work area. It + * By default, FOUND() operates on the currently selected work area. It * can be made to operate on an unselected work area by specifying it * within an aliased expression (see example below). * * FOUND() will return false (.F.) if there is no database open in the * current work area. * $EXAMPLES$ - * This example illustrates the behavior of FOUND() after a + * This example illustrates the behavior of FOUND() after a * record movement command: * * USE Sales INDEX Sales @@ -5433,7 +5235,7 @@ HARBOUR HB_FLOCK( void ) * SKIP * ? FOUND() // Result: .F. * - * This example tests a FOUND() value in an unselected work area + * This example tests a FOUND() value in an unselected work area * using an aliased expression: * * USE Sales INDEX Sales NEW @@ -5443,7 +5245,7 @@ HARBOUR HB_FLOCK( void ) * SEEK "Smith" * ? FOUND(), Sales->(FOUND()) * - * This code fragment processes all Customer records with the key + * This code fragment processes all Customer records with the key * value "Smith" using FOUND() to determine when the key value changes: * * USE Customer INDEX Customer NEW @@ -5458,13 +5260,13 @@ HARBOUR HB_FLOCK( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * EOF() + * EOF() * $INCLUDE$ - * + * * $END$ */ @@ -5478,15 +5280,15 @@ HARBOUR HB_FOUND( void ) } /* $DOC$ * $FUNCNAME$ - * HEADER() + * HEADER() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the current database file header length + * Return the current database file header length * $SYNTAX$ - * HEADER() --> nBytes + * HEADER() --> nBytes * $ARGUMENTS$ - * + * * $RETURNS$ HEADER() returns the number of bytes in the header of the current database file as an integer numeric value. If no database file is in @@ -5520,13 +5322,13 @@ HARBOUR HB_FOUND( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DISKSPACE(),LASTREC(),RECSIZE() + * DISKSPACE(),LASTREC(),RECSIZE() * $INCLUDE$ - * + * * $END$ */ @@ -5546,15 +5348,15 @@ HARBOUR HB_HEADER( void ) } /* $DOC$ * $FUNCNAME$ - * INDEXORD() + * INDEXORD() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the order position of the controlling index + * Return the order position of the controlling index * $SYNTAX$ - * INDEXORD() --> nOrder + * INDEXORD() --> nOrder * $ARGUMENTS$ - * + * * $RETURNS$ INDEXORD() returns an integer numeric value. The value returned is equal to the position of the controlling index in the list of open @@ -5591,13 +5393,13 @@ HARBOUR HB_HEADER( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * INDEXKEY() + * INDEXKEY() * $INCLUDE$ - * + * * $END$ */ @@ -5617,15 +5419,15 @@ HARBOUR HB_INDEXORD( void ) } /* $DOC$ * $FUNCNAME$ - * LASTREC() + * LASTREC() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Determine the number of records in the current (.dbf) file + * Determine the number of records in the current (.dbf) file * $SYNTAX$ * LASTREC() | RECCOUNT()* --> nRecords * $ARGUMENTS$ - * + * * $RETURNS$ LASTREC() returns the number of physical records in the current database file as an integer numeric value. Filtering commands such as SET FILTER @@ -5659,13 +5461,13 @@ HARBOUR HB_INDEXORD( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * EOF() + * EOF() * $INCLUDE$ - * + * * $END$ */ @@ -5692,20 +5494,20 @@ HARBOUR HB_LOCK( void ) } /* $DOC$ * $FUNCNAME$ - * LUPDATE() + * LUPDATE() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the last modification date of a (.dbf) file + * Return the last modification date of a (.dbf) file * $SYNTAX$ - * LUPDATE() --> dModification + * LUPDATE() --> dModification * $ARGUMENTS$ - * + * * $RETURNS$ LUPDATE() returns the date of last change to the open database file in the current work area. If there is no database file in USE, LUPDATE() returns a blank date. - * + * * $DESCRIPTION$ LUPDATE() is a database function that determines the date the database file in the current work area was last modified and CLOSEd. By default, @@ -5736,13 +5538,13 @@ HARBOUR HB_LOCK( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ * FIELDNAME(),LASTREC(),RECSIZE() * $INCLUDE$ - * + * * $END$ */ @@ -5755,20 +5557,20 @@ HARBOUR HB_LUPDATE( void ) } /* $DOC$ * $FUNCNAME$ - * NETERR() + * NETERR() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Determine if a network command has failed + * Determine if a network command has failed * $SYNTAX$ - * NETERR([]) --> lError + * NETERR([]) --> lError * $ARGUMENTS$ if specified sets the value returned by NETERR() to the specified status. can be either true (.T.) or false (.F.). Setting NETERR() to a specified value allows the runtime error handler to control the way certain file errors are handled. For more information, refer to Errorsys.prg. - * + * * $RETURNS$ NETERR() returns true (.T.) if a USE or APPEND BLANK fails. The initial value of NETERR() is false (.F.). If the current process is not running @@ -5811,13 +5613,13 @@ HARBOUR HB_LUPDATE( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * FLOCK(),RLOCK() + * FLOCK(),RLOCK() * $INCLUDE$ - * + * * $END$ */ @@ -5830,17 +5632,17 @@ HARBOUR HB_NETERR( void ) } /* $DOC$ * $FUNCNAME$ - * ORDBAGEXT() + * ORDBAGEXT() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the default Order Bag RDD extension + * Return the default Order Bag RDD extension * $SYNTAX$ - * ORDBAGEXT() --> cBagExt + * ORDBAGEXT() --> cBagExt * $ARGUMENTS$ - * + * * $RETURNS$ - * ORDBAGEXT() returns a character expression. + * ORDBAGEXT() returns a character expression. * $DESCRIPTION$ ORDBAGEXT() is an Order management function that returns a character expression that is the default Order Bag extension of the current or @@ -5848,7 +5650,7 @@ HARBOUR HB_NETERR( void ) current work area. ORDBAGEXT() supersedes the INDEXEXT() and is not recommended. - * + * * $EXAMPLES$ USE sample VIA "DBFNTX" ? ORDBAGEXT() // Returns .ntx @@ -5856,13 +5658,13 @@ HARBOUR HB_NETERR( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ * INDEXEXT(),ORDBAGNAME() * $INCLUDE$ - * + * * $END$ */ @@ -5918,20 +5720,20 @@ HARBOUR HB_ORDBAGEXT( void ) } /* $DOC$ * $FUNCNAME$ - * ORDBAGNAME() + * ORDBAGNAME() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the Order Bag name of a specific Order + * Return the Order Bag name of a specific Order * $SYNTAX$ - * ORDBAGNAME( | ) --> cOrderBagName + * ORDBAGNAME( | ) --> cOrderBagName * $ARGUMENTS$ is an integer that identifies the position in the Order List of the target Order whose Order Bag name is sought. is a character string that represents the name of the target Order whose Order Bag name is sought. - * + * * $RETURNS$ ORDBAGNAME() returns a character string, the Order Bag name of the specific Order. @@ -5963,13 +5765,13 @@ HARBOUR HB_ORDBAGEXT( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * ORDBAGEXT() + * ORDBAGEXT() * $INCLUDE$ - * + * * $END$ */ @@ -5997,13 +5799,13 @@ HARBOUR HB_ORDBAGNAME( void ) } /* $DOC$ * $FUNCNAME$ - * ORDCONDSET() + * ORDCONDSET() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Set the Condition and scope for an order + * Set the Condition and scope for an order * $SYNTAX$ - * ORDCONSET([], + * ORDCONSET([], [], [], [], @@ -6019,7 +5821,7 @@ HARBOUR HB_ORDBAGNAME( void ) [], []) * $ARGUMENTS$ - * is a string that specifies the FOR condition for the + * is a string that specifies the FOR condition for the order. is a code block that defines a FOR condition that each record within the scope must meet in order to be processed. If @@ -6027,21 +5829,21 @@ HARBOUR HB_ORDBAGNAME( void ) next record is processed.Duplicate keys values are not added to the index file when a FOR condition is Used. * $RETURNS$ - * + * * $DESCRIPTION$ - * + * * $EXAMPLES$ * * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ - * ORDCONDSET() is CA-CLIPPER 5.3 Compilant + * ORDCONDSET() is CA-CLIPPER 5.3 Compilant * $SEEALSO$ - * + * * $INCLUDE$ - * + * * $END$ */ @@ -6113,11 +5915,11 @@ HARBOUR HB_ORDCONDSET( void ) } /* $DOC$ * $FUNCNAME$ - * ORDCREATE() + * ORDCREATE() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Create an Order in an Order Bag + * Create an Order in an Order Bag * $SYNTAX$ ORDCREATE(,[], , [], []) --> NIL @@ -6146,7 +5948,7 @@ HARBOUR HB_ORDCONDSET( void ) unique Order is to be created. If is omitted, the current global _SET_UNIQUE setting is used. * $RETURNS$ - * ORDCREATE() always returns NIL. + * ORDCREATE() always returns NIL. * $DESCRIPTION$ ORDCREATE() is an Order management function that creates an Order in the current work area. It works like DBCREATEINDEX() except that it lets @@ -6208,13 +6010,13 @@ HARBOUR HB_ORDCONDSET( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * DBCREATEINDEX() + * DBCREATEINDEX() * $INCLUDE$ - * + * * $END$ */ @@ -6246,9 +6048,9 @@ HARBOUR HB_ORDCREATE( void ) } /* $DOC$ * $FUNCNAME$ - * ORDDESTROY() + * ORDDESTROY() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ * Remove a specified Order from an Order Bag * $SYNTAX$ @@ -6263,7 +6065,7 @@ HARBOUR HB_ORDCREATE( void ) extension as part of HARBOUR uses the default extension of the current RDD. * $RETURNS$ - * ORDDESTROY() always returns NIL. + * ORDDESTROY() always returns NIL. * $DESCRIPTION$ ORDDESTROY() is an Order management function that removes a specified Order from multiple-Order Bags. @@ -6286,13 +6088,13 @@ HARBOUR HB_ORDCREATE( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * ORDCREATE() + * ORDCREATE() * $INCLUDE$ - * + * * $END$ */ @@ -6311,15 +6113,15 @@ HARBOUR HB_ORDDESTROY( void ) } /* $DOC$ * $FUNCNAME$ - * ORDFOR() + * ORDFOR() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the FOR expression of an Order + * Return the FOR expression of an Order * $SYNTAX$ ORDFOR( | [, ]) --> cForExp - * + * * $ARGUMENTS$ is the name of the target Order, whose cForExp is sought. @@ -6355,13 +6157,13 @@ HARBOUR HB_ORDDESTROY( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * ORDKEY(),ORDCREATE(),ORDNAME(),ORDNUMBER() + * ORDKEY(),ORDCREATE(),ORDNAME(),ORDNUMBER() * $INCLUDE$ - * + * * $END$ */ @@ -6390,11 +6192,11 @@ HARBOUR HB_ORDFOR( void ) } /* $DOC$ * $FUNCNAME$ - * ORDKEY() + * ORDKEY() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the key expression of an Order + * Return the key expression of an Order * $SYNTAX$ ORDKEY( | [, ]) --> cExpKey @@ -6411,7 +6213,7 @@ HARBOUR HB_ORDFOR( void ) extension as part of HARBOUR uses the default extension of the current RDD. * $RETURNS$ - * Returns a character string, cExpKey. + * Returns a character string, cExpKey. * $DESCRIPTION$ ORDKEY() is an Order management function that returns a character expression, cExpKey, that represents the key expression of the specified @@ -6437,13 +6239,13 @@ HARBOUR HB_ORDFOR( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * ORDFOR(),ORDNAME(),ORDNUMBER() + * ORDFOR(),ORDNAME(),ORDNUMBER() * $INCLUDE$ - * + * * $END$ */ @@ -6472,11 +6274,11 @@ HARBOUR HB_ORDKEY( void ) } /* $DOC$ * $FUNCNAME$ - * ORDLISTADD() + * ORDLISTADD() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Add Orders to the Order List + * Add Orders to the Order List * $SYNTAX$ ORDLISTADD( [, ]) --> NIL @@ -6492,7 +6294,7 @@ HARBOUR HB_ORDKEY( void ) , all orders in the Order Bag are added to the Order List of the current work area. * $RETURNS$ - * ORDLISTADD() always returns NIL. + * ORDLISTADD() always returns NIL. * $DESCRIPTION$ ORDLISTADD() is an Order management function that adds the contents of an Order Bag , or a single Order in an Order Bag, to the Order List. @@ -6530,13 +6332,13 @@ HARBOUR HB_ORDKEY( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * DBSETINDEX() + * DBSETINDEX() * $INCLUDE$ - * + * * $END$ */ @@ -6560,24 +6362,24 @@ HARBOUR HB_ORDLISTADD( void ) } /* $DOC$ * $FUNCNAME$ - * ORDLISTCLEAR() + * ORDLISTCLEAR() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Clear the current Order List + * Clear the current Order List * $SYNTAX$ - * ORDLISTCLEAR() --> NIL + * ORDLISTCLEAR() --> NIL * $ARGUMENTS$ - * + * * $RETURNS$ - * ORDLISTCLEAR() always returns NIL. + * ORDLISTCLEAR() always returns NIL. * $DESCRIPTION$ ORDLISTCLEAR() is an Order management function that removes all Orders from the Order List for the current or aliased work area. When you are done, the Order List is empty. This function supersedes the function DBCLEARINDEX(). - * + * * $EXAMPLES$ USE Sales NEW SET INDEX TO SaRegion, SaRep, SaCode @@ -6588,13 +6390,13 @@ HARBOUR HB_ORDLISTADD( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ * DBCLEARINDEX() * $INCLUDE$ - * + * * $END$ */ @@ -6607,17 +6409,17 @@ HARBOUR HB_ORDLISTCLEAR( void ) } /* $DOC$ * $FUNCNAME$ - * ORDLISTREBUILD() + * ORDLISTREBUILD() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Rebuild all Orders in the Order List of the current work area + * Rebuild all Orders in the Order List of the current work area * $SYNTAX$ - * ORDLISTREBUILD() --> NIL + * ORDLISTREBUILD() --> NIL * $ARGUMENTS$ - * + * * $RETURNS$ - * ORDLISTREBUILD() always returns NIL. + * ORDLISTREBUILD() always returns NIL. * $DESCRIPTION$ ORDLISTREBUILD() is an Order management function that rebuilds all the orders in the current or aliased Order List. @@ -6626,7 +6428,7 @@ HARBOUR HB_ORDLISTCLEAR( void ) Unlike ORDCREATE(), this function rebuilds all Orders in the Order List. It is equivalent to REINDEX. - * + * * $EXAMPLES$ USE Customer NEW SET INDEX TO CuAcct, CuName, CuZip @@ -6636,13 +6438,13 @@ HARBOUR HB_ORDLISTCLEAR( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ * ORDCREATE() * $INCLUDE$ - * + * * $END$ */ @@ -6655,13 +6457,13 @@ HARBOUR HB_ORDLISTREBUILD( void ) } /* $DOC$ * $FUNCNAME$ - * ORDNAME() + * ORDNAME() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the name of an Order in the Order List + * Return the name of an Order in the Order List * $SYNTAX$ - * ORDNAME([,]) + * ORDNAME([,]) --> cOrderName * $ARGUMENTS$ is an integer that identifies the position in the Order @@ -6705,13 +6507,13 @@ HARBOUR HB_ORDLISTREBUILD( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * ORDFOR(),ORDKEY(),ORDNUMBER() + * ORDFOR(),ORDKEY(),ORDNUMBER() * $INCLUDE$ - * + * * $END$ */ @@ -6738,9 +6540,9 @@ HARBOUR HB_ORDNAME( void ) } /* $DOC$ * $FUNCNAME$ - * ORDNUMBER() + * ORDNUMBER() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ * Return the position of an Order in the current Order List * $SYNTAX$ @@ -6780,13 +6582,13 @@ HARBOUR HB_ORDNAME( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * INDEXORD() + * INDEXORD() * $INCLUDE$ - * + * * $END$ */ @@ -6813,15 +6615,15 @@ HARBOUR HB_ORDNUMBER( void ) } /* $DOC$ * $FUNCNAME$ - * ORDSETFOCUS() + * ORDSETFOCUS() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Set focus to an Order in an Order List + * Set focus to an Order in an Order List * $SYNTAX$ ORDSETFOCUS([ | ] [,]) --> cPrevOrderNameInFocus - * + * * $ARGUMENTS$ is the name of the selected Order, a logical ordering of a database. ORDSETFOCUS() ignores any invalid values of @@ -6836,7 +6638,7 @@ HARBOUR HB_ORDNUMBER( void ) extension as part of HARBOUR uses the default extension of the current RDD. * $RETURNS$ - * ORDSETFOCUS() returns the Order Name of the previous controlling Order. + * ORDSETFOCUS() returns the Order Name of the previous controlling Order. * $DESCRIPTION$ ORDSETFOCUS() is an Order management function that returns the Order Name of the previous controlling Order and optionally sets the focus to @@ -6864,13 +6666,13 @@ HARBOUR HB_ORDNUMBER( void ) * $TESTS$ * * $STATUS$ - * S + * S * $COMPLIANCE$ * * $SEEALSO$ - * + * * $INCLUDE$ - * + * * $END$ */ @@ -6894,13 +6696,13 @@ HARBOUR HB_ORDSETFOCUS( void ) } /* $DOC$ * $FUNCNAME$ - * RDDLIST() + * RDDLIST() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ * Return an array of the available Replaceable Database Drivers * $SYNTAX$ - * RDDLIST([]) --> aRDDList + * RDDLIST([]) --> aRDDList * $ARGUMENTS$ is an integer that represents the type of the RDD you wish to list. The constants RDT_FULL and RDT_TRANSFER represent the two @@ -6957,13 +6759,13 @@ HARBOUR HB_ORDSETFOCUS( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * + * * $INCLUDE$ - * RDDSYS.CH + * RDDSYS.CH * $END$ */ @@ -6988,23 +6790,23 @@ HARBOUR HB_RDDLIST( void ) } /* $DOC$ * $FUNCNAME$ - * RDDNAME() + * RDDNAME() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the name of the currently active RDD + * Return the name of the currently active RDD * $SYNTAX$ - * RDDNAME() --> cRDDName + * RDDNAME() --> cRDDName * $ARGUMENTS$ - * + * * $RETURNS$ - * Returns a character string, cRDDName, the registered name of the active + * Returns a character string, cRDDName, the registered name of the active * RDD in the current or specified work area. * $DESCRIPTION$ - * RDDNAME() is an RDD function that returns a character string, cRDDName, + * RDDNAME() is an RDD function that returns a character string, cRDDName, * the name of the active RDD in the current or specified work area. * - * You can specify a work area other than the currently active work area by + * You can specify a work area other than the currently active work area by * aliasing the function. * $EXAMPLES$ * USE Customer VIA "DBFNTX" NEW @@ -7016,13 +6818,13 @@ HARBOUR HB_RDDLIST( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * RDDLIST() + * RDDLIST() * $INCLUDE$ - * + * * $END$ */ @@ -7069,25 +6871,25 @@ HARBOUR HB_RDDREGISTER( void ) } /* $DOC$ * $FUNCNAME$ - * RDDSETDEFAULT() + * RDDSETDEFAULT() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Set or return the default RDD for the application + * Set or return the default RDD for the application * $SYNTAX$ - * RDDSETDEFAULT([]) + * RDDSETDEFAULT([]) * --> cPreviousDefaultRDD - * + * * $ARGUMENTS$ - * is a character string, the name of the RDD that is + * is a character string, the name of the RDD that is * to be made the new default RDD in the application. * $RETURNS$ - * RDDSETDEFAULT() returns a character string, cPreviousDefaultRDD, the + * RDDSETDEFAULT() returns a character string, cPreviousDefaultRDD, the * name of the previous default driver. The default driver is the driver * that HARBOUR uses if you do not explicitly specify an RDD with the * VIA clause of the USE command. * $DESCRIPTION$ - * RDDSETDEFAULT() is an RDD function that sets or returns the name of the + * RDDSETDEFAULT() is an RDD function that sets or returns the name of the * previous default RDD driver and, optionally, sets the current driver to * the new RDD driver specified by cNewDefaultRDD. If * is not specified, the current default driver name is returned and @@ -7103,13 +6905,13 @@ HARBOUR HB_RDDREGISTER( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBSETDRIVER() + * DBSETDRIVER() * $INCLUDE$ - * + * * $END$ */ @@ -7138,22 +6940,22 @@ HARBOUR HB_RDDSETDEFAULT( void ) } /* $DOC$ * $FUNCNAME$ - * RECCOUNT() + * RECCOUNT() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Determine the number of records in the current (.dbf) file + * Determine the number of records in the current (.dbf) file * $SYNTAX$ - * RECCOUNT()* | LASTREC() --> nRecords + * RECCOUNT()* | LASTREC() --> nRecords * $ARGUMENTS$ - * + * * $RETURNS$ RECCOUNT() returns the number of physical records in the current database file as an integer numeric value. Filtering commands such as SET FILTER or SET DELETED have no effect on the return value. RECCOUNT() returns zero if there is no database file open in the current work area. - * + * * $DESCRIPTION$* RECCOUNT() is a database function that is a synonym for LASTREC(). By default, RECCOUNT() operates on the currently selected work area. It @@ -7180,13 +6982,13 @@ HARBOUR HB_RDDSETDEFAULT( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * EOF(),LASTREC() + * EOF(),LASTREC() * $INCLUDE$ - * + * * $END$ */ @@ -7203,15 +7005,15 @@ HARBOUR HB_RECCOUNT( void ) } /* $DOC$ * $FUNCNAME$ - * RECNO() + * RECNO() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Return the identity at the position of the record pointer + * Return the identity at the position of the record pointer * $SYNTAX$ - * RECNO() --> Identity + * RECNO() --> Identity * $ARGUMENTS$ - * + * * $RETURNS$ RECNO() returns the identity found at the position of the record pointer. @@ -7238,13 +7040,13 @@ HARBOUR HB_RECCOUNT( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBGOTO() + * DBGOTO() * $INCLUDE$ - * + * * $END$ */ @@ -7260,15 +7062,15 @@ HARBOUR HB_RECNO( void ) } /* $DOC$ * $FUNCNAME$ - * RECSIZE() + * RECSIZE() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Determine the record length of a database (.dbf) file + * Determine the record length of a database (.dbf) file * $SYNTAX$ - * RECSIZE() --> nBytes + * RECSIZE() --> nBytes * $ARGUMENTS$ - * + * * $RETURNS$ RECSIZE() returns, as a numeric value, the record length, in bytes, of the database file open in the current work area. RECSIZE() returns zero @@ -7305,13 +7107,13 @@ HARBOUR HB_RECNO( void ) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ * DISKSPACE(),FIELDNAME(),HEADER(),LASTREC() * $INCLUDE$ - * + * * $END$ */ @@ -7331,94 +7133,92 @@ HARBOUR HB_RECSIZE( void ) } /* $DOC$ * $FUNCNAME$ - * RLOCK() + * RLOCK() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Lock the current record in the active work area + * Lock the current record in the active work area * $SYNTAX$ - * RLOCK() --> lSuccess + * RLOCK() --> lSuccess * $ARGUMENTS$ - * + * * $RETURNS$ RLOCK() returns true (.T.) if the record lock is obtained; otherwise, it returns false (.F.). * $DESCRIPTION$ RLOCK() is a network function that locks the current record, preventing - other users from updating the record until the lock is released. - RLOCK() provides a shared lock, allowing other users read-only access to - the locked record while allowing only the current user to modify it. A - record lock remains until another record is locked, an UNLOCK is - executed, the current database file is closed, or an FLOCK() is obtained - on the current database file. + other users from updating the record until the lock is released. + RLOCK() provides a shared lock, allowing other users read-only access to + the locked record while allowing only the current user to modify it. A + record lock remains until another record is locked, an UNLOCK is + executed, the current database file is closed, or an FLOCK() is obtained + on the current database file. - For each invocation of RLOCK(), there is one attempt to lock the current - record, and the result is returned as a logical value. An attempt to - obtain a record lock fails if another user currently has a file or - record lock, or EXCLUSIVE USE of the database file. An attempt to - RLOCK() in an empty database returns true (.T.). + For each invocation of RLOCK(), there is one attempt to lock the current + record, and the result is returned as a logical value. An attempt to + obtain a record lock fails if another user currently has a file or + record lock, or EXCLUSIVE USE of the database file. An attempt to + * RLOCK() in an empty database returns true (.T.). - By default, RLOCK() operates on the currently selected work area. It - will operate on an unselected work area if you specify it as part of an - aliased expression (see example below). This feature is useful since - RLOCK() does not automatically attempt a record lock for related files. + * By default, RLOCK() operates on the currently selected work area. It + * will operate on an unselected work area if you specify it as part of an + * aliased expression (see example below). This feature is useful since + * RLOCK() does not automatically attempt a record lock for related files. - As a general rule, RLOCK() operates solely on the current record. This - includes the following commands: + * As a general rule, RLOCK() operates solely on the current record. This + * includes the following commands: - @...GET + * @...GET - DELETE (single record) + * DELETE (single record) - RECALL (single record) + * RECALL (single record) - REPLACE (single record) + * REPLACE (single record) - Refer to the Network Programming chapter in the Programming and - Utilities guide for more information. - Notes + * Notes - SET RELATION: HARBOUR does not automatically lock all - records in the relation chain when you lock the current work area - record. Also, an UNLOCK has no effect on related work areas. + * SET RELATION: HARBOUR does not automatically lock all + * records in the relation chain when you lock the current work area + * record. Also, an UNLOCK has no effect on related work areas. * $EXAMPLES$ This example deletes a record in a network environment, using - RLOCK(): + * RLOCK(): - USE Customer INDEX CustName SHARED NEW - SEEK "Smith" - IF FOUND() - IF RLOCK() - DELETE - ? "Smith deleted" - ELSE - ? "Record in use by another" - ENDIF - ELSE - ? "Smith not in Customer file" - ENDIF - CLOSE + * USE Customer INDEX CustName SHARED NEW + * SEEK "Smith" + * IF FOUND() + * IF RLOCK() + * DELETE + * ? "Smith deleted" + * ELSE + * ? "Record in use by another" + * ENDIF + * ELSE + * ? "Smith not in Customer file" + * ENDIF + * CLOSE - This example specifies RLOCK() as an aliased expression to - lock a record in an unselected work area: + * This example specifies RLOCK() as an aliased expression to + * lock a record in an unselected work area: - USE Sales SHARED NEW - USE Customer SHARED NEW - // - IF !Sales->(RLOCK()) - ? "The current Sales record is in use by another" - ENDIF + * USE Sales SHARED NEW + * USE Customer SHARED NEW + * // + * IF !Sales->(RLOCK()) + * ? "The current Sales record is in use by another" + * ENDIF * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * FLOCK() + * FLOCK() * $INCLUDE$ - * + * * $END$ */ @@ -7444,53 +7244,53 @@ HARBOUR HB_RLOCK( void ) } /* $DOC$ * $FUNCNAME$ - * SELECT() + * SELECT() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Determine the work area number of a specified alias + * Determine the work area number of a specified alias * $SYNTAX$ - * SELECT([]) --> nWorkArea + * SELECT([]) --> nWorkArea * $ARGUMENTS$ - * is the target work area alias name. + * is the target work area alias name. * $RETURNS$ - SELECT() returns the work area of the specified alias as a integer - numeric value. + * SELECT() returns the work area of the specified alias as a integer + * numeric value. * $DESCRIPTION$ - SELECT() is a database function that determines the work area number of - an alias. The number returned can range from zero to 250. If - is not specified, the current work area number is returned. If - is specified and the alias does not exist, SELECT() returns zero. + * SELECT() is a database function that determines the work area number of + * an alias. The number returned can range from zero to 250. If + * is not specified, the current work area number is returned. If + * is specified and the alias does not exist, SELECT() returns zero. - Note: The SELECT() function and SELECT command specified with an - extended expression argument look somewhat alike. This shouldn't be a - problem since the SELECT() function is not very useful on a line by - itself + * Note: The SELECT() function and SELECT command specified with an + * extended expression argument look somewhat alike. This shouldn't be a + * problem since the SELECT() function is not very useful on a line by + * itself * $EXAMPLES$ This example uses SELECT() to determine which work area - USE...NEW selected: + * USE...NEW selected: - USE Sales NEW - SELECT 1 - ? SELECT("Sales") // Result: 4 + * USE Sales NEW + * SELECT 1 + * ? SELECT("Sales") // Result: 4 - To reselect the value returned from the SELECT() function, use - the SELECT command with the syntax, SELECT (), like this: + * To reselect the value returned from the SELECT() function, use + * the SELECT command with the syntax, SELECT (), like this: - USE Sales NEW - nWorkArea:= SELECT() - USE Customer NEW - SELECT (nWorkArea) + * USE Sales NEW + * nWorkArea:= SELECT() + * USE Customer NEW + * SELECT (nWorkArea) * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ * ALIAS(),USED() * $INCLUDE$ - * + * * $END$ */ @@ -7511,41 +7311,41 @@ HARBOUR HB_SELECT( void ) } /* $DOC$ * $FUNCNAME$ - * USED() + * USED() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Determine whether a database file is in USE + * Determine whether a database file is in USE * $SYNTAX$ - * USED() --> lDbfOpen + * USED() --> lDbfOpen * $ARGUMENTS$ - * + * * $RETURNS$ - USED() returns true (.T.) if there is a database file in USE; otherwise, - it returns false (.F.). + * USED() returns true (.T.) if there is a database file in USE; otherwise, + * it returns false (.F.). * $DESCRIPTION$ - USED() is a database function that determines whether there is a - database file in USE in a particular work area. By default, USED() - operates on the currently selected work area. It will operate on an - unselected work area if you specify it as part of an aliased expression. + * USED() is a database function that determines whether there is a + * database file in USE in a particular work area. By default, USED() + * operates on the currently selected work area. It will operate on an + * unselected work area if you specify it as part of an aliased expression. * $EXAMPLES$ - This example determines whether a database file is in USE in - the current work area: + * This example determines whether a database file is in USE in + * the current work area: - USE Customer NEW - ? USED() // Result: .T. - CLOSE - ? USED() // Result: .F. + * USE Customer NEW + * ? USED() // Result: .T. + * CLOSE + * ? USED() // Result: .F. * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * ALIAS(),SELECT() + * ALIAS(),SELECT() * $INCLUDE$ - * + * * $END$ */ @@ -7555,53 +7355,53 @@ HARBOUR HB_USED( void ) } /* NOTE: Same as dbSetDriver() and rddSetDefault(), but doesn't - throw any error if the driver doesn't exist, this is - required in the RDDSYS INIT function, since it's not guaranteed - that the RDD is already registered at that point. */ + * throw any error if the driver doesn't exist, this is + * required in the RDDSYS INIT function, since it's not guaranteed + * that the RDD is already registered at that point. */ /* $DOC$ * $FUNCNAME$ - * __RDDSETDEFAULT() + * __RDDSETDEFAULT() * $CATEGORY$ - * Data Base + * Data Base * $ONELINER$ - * Set or return the default RDD for the application + * Set or return the default RDD for the application * $SYNTAX$ - __RDDSETDEFAULT([]) - --> cPreviousDefaultRDD - * + * __RDDSETDEFAULT([]) + * --> cPreviousDefaultRDD + * * $ARGUMENTS$ - is a character string, the name of the RDD that is - to be made the new default RDD in the application. + * is a character string, the name of the RDD that is + * to be made the new default RDD in the application. * $RETURNS$ - __RDDSETDEFAULT() returns a character string, cPreviousDefaultRDD, the - name of the previous default driver. The default driver is the driver - that HARBOUR uses if you do not explicitly specify an RDD with the - VIA clause of the USE command. + * __RDDSETDEFAULT() returns a character string, cPreviousDefaultRDD, the + * name of the previous default driver. The default driver is the driver + * that HARBOUR uses if you do not explicitly specify an RDD with the + * VIA clause of the USE command. * $DESCRIPTION$ - RDDSETDEFAULT() is an RDD function that sets or returns the name of the - previous default RDD driver and, optionally, sets the current driver to - the new RDD driver specified by cNewDefaultRDD. If - is not specified, the current default driver name is returned and - continues to be the current default driver. + * RDDSETDEFAULT() is an RDD function that sets or returns the name of the + * previous default RDD driver and, optionally, sets the current driver to + * the new RDD driver specified by cNewDefaultRDD. If + * is not specified, the current default driver name is returned and + * continues to be the current default driver. - This function replaces the DBSETDRIVER() function. + * This function replaces the DBSETDRIVER() function. * $EXAMPLES$ - // If the default driver is not DBFNTX, make it the default + * // If the default driver is not DBFNTX, make it the default - IF ( __RDDSETDEFAULT() != "DBFNTX" ) - cOldRdd := __RDDSETDEFAULT( "DBFNTX" ) - ENDIF + * IF ( __RDDSETDEFAULT() != "DBFNTX" ) + * cOldRdd := __RDDSETDEFAULT( "DBFNTX" ) + * ENDIF * $TESTS$ * * $STATUS$ - * R + * R * $COMPLIANCE$ * * $SEEALSO$ - * DBSETDRIVER() + * DBSETDRIVER() * $INCLUDE$ - * + * * $END$ */ diff --git a/harbour/source/rtl/arrays.c b/harbour/source/rtl/arrays.c index 6cf7d60f96..8c77686885 100644 --- a/harbour/source/rtl/arrays.c +++ b/harbour/source/rtl/arrays.c @@ -786,6 +786,47 @@ static void hb_arrayNewRagged( PHB_ITEM pArray, int iDimension ) hb_arrayNewRagged( hb_arrayGetItemPtr( pArray, ulElements-- ), iDimension ); } } +/* $DOC$ + * $FUNCNAME$ + * ARRAY() + * $CATEGORY$ + * ARRAY + * $ONELINER$ + * Create an uninitialized array of specified length + * $SYNTAX$ + * ARRAY( [, ...]) --> aArray + * $ARGUMENTS$ + * is the number of elements in the specified dimension. + * $RETURNS$ + * ARRAY() returns an array of specified dimensions. + * $DESCRIPTION$ + * This function returns an uninitialized array with the lenght of + * .Nested arrays are uninitialized whitin the same array + * pointer reference if additional parameters are specified. + * Establishing a memory variable with the same name as the array + * may destroy the original array and release the entire contents of + * the array.This is,of course, on the data storage type of either array + * or the variable with the same name as the array. + * $EXAMPLES$ + * FUNCTION Main() + * LOCAL aArray:=Array(10) + * LOCAL x:=1 + * FOR x:=1 to LEN(aArray) + * aArray[x]:=Array(x) + * NEXT + * Return Nil + * $STATUS$ + * R + * $SEEALSO$ + * AADD(),ADEL(),AFILL(),AINS() + * $COMPLIANCE$ + * This Function is CA-CLIPPER Compilance in all Cases, except + * that arrays in Harbour can have an unlimited number of dimensions, + * while Clipper has a limmit of 4096 array elements. + * $INCLUDE$ + * + * $END$ + */ HARBOUR HB_ARRAY( void ) { @@ -816,6 +857,42 @@ HARBOUR HB_ARRAY( void ) hb_arrayNewRagged( &hb_stack.Return, 1 ); } } +/* $DOC$ + * $FUNCNAME$ + * AADD() + * $CATEGORY$ + * ARRAY + * $ONELINER$ + * Dinamically adda an element to an array + * $SYNTAX$ + * AADD([, ]) --> Value + * $ARGUMENTS$ + * The name of an array + * + * Element to add to array + * $RETURNS$ + * The value of if specified,otherwise this function + * returns a NIL value. + * $DESCRIPTION$ + * This function dinamically increase the lenght of the array + * named by one element and stores the value of to + * that newly created element. + * may be an array reference pointer, which in turn may be + * stored to an array's subscript position. + * $EXAMPLES$ + * LOCAL aArray:={} + * AADD(aArray,10) + * FOR x:=1 to 10 + * AADD(aArray,x) + * NEXT + * $STATUS$ + * R + * $SEEALSO$ + * AINS(),ASIZE() + * $INCLUDE$ + * + * $END$ + */ HARBOUR HB_AADD( void ) { @@ -844,6 +921,44 @@ HARBOUR HB_AADD( void ) /* NOTE: CA-Cl*pper 5.3 and older will return NIL on bad parameter, 5.3a,b will throw a runtime error. [vszel] */ +/* $DOC$ + * $FUNCNAME$ + * ASIZE() + * $CATEGORY$ + * ARRAY + * $ONELINER$ + * Adjust the size of an array + * $SYNTAX$ + * ASIZE(, ) --> aTarget + * $ARGUMENTS$ + * Name od array to be dinamically altered + * + * Numeric value representing the new size of + * $RETURNS$ + * ASIZE() returns an array pointer reference to . + * $DESCRIPTION$ + * This function will dinamically increase or decrease the size + * of by ajusting the lenght of the array to subscript + * positions. + * If the lenght of the array is shortened,those former + * subscripts positions are lost.If the lenght of the array is lenghtened + * a NIL data value is assigned to the new subscript position. + * $EXAMPLES$ + * aArray := { 1 } // Result: aArray is { 1 } + * ASIZE(aArray, 3) // Result: aArray is { 1, NIL, NIL } + * ASIZE(aArray, 1) // Result: aArray is { 1 } + * $TESTS$ + * $STATUS$ + * R + * $COMPLIANCE$ + * If HB_COMPAT_C53 is defined, the function generates an Error, + * else it will return the array itself. + * $SEEALSO$ + * AADD(),ADEL(),AFILL(),AINS() + * $INCLUDE$ + * + * $END$ + */ HARBOUR HB_ASIZE( void ) { @@ -862,6 +977,36 @@ HARBOUR HB_ASIZE( void ) hb_errRT_BASE( EG_ARG, 2023, NULL, "ASIZE" ); #endif } +/* $DOC$ + * $FUNCNAME$ + * ATAIL() + * $CATEGORY$ + * ARRAY + * $ONELINER$ + * Returns the rightmost element of an array + * $SYNTAX$ + * ATAIL() --> Element + * $ARGUMENTS$ + * is the array. + * $RETURNS$ + * Atail() return the expression of the last element in the array. + * $DESCRIPTION$ + * This function return the value of the last element in the array named + * .This function does not alter the size of the array or any of + * the subscript values. + * $EXAMPLES$ + * LOCAL array:= {"Harbour", "is", "Supreme", "Power"} + * ? ATAIL(aArray) + * $TESTS$ + * $STATUS$ + * R + * $COMPLIANCE$ + * $SEEALSO$ + * LEN(),ARRAY(),ASIZE(),AADD() + * $INCLUDE$ + * + * $END$ + */ HARBOUR HB_ATAIL( void ) { @@ -870,6 +1015,43 @@ HARBOUR HB_ATAIL( void ) if( pArray ) hb_arrayLast( pArray, &hb_stack.Return ); } +/* $DOC$ + * $FUNCNAME$ + * AINS() + * $CATEGORY$ + * ARRAY + * $ONELINER$ + * Insert a NIL valueat an array subscript position. + * $SYNTAX$ + * AINS(, ) --> aTarget + * $ARGUMENTS$ + * Array name. + * + * Subscript position in + * $RETURNS$ + * AINS() returns a array pointer reference to . + * $DESCRIPTION$ + * This function inserts a NIL value in the array named + * at the th position. + * All array elements starting with the th position will be + * shifted down one subscript position in the array list and the last + * item in the array will be removed completly.In other words,if an array + * element were to be inserted at the fifth subscript position, the element + * previosly in the fifth position would now be located at sixth position. + * The lenght of the array will remain unchanged + * $EXAMPLES$ + * LOCAL aArray:={"Harbour","is","Power!","!!!"} + * AINS(aArray,4) + * $TESTS$ + * $STATUS$ + * R + * $COMPLIANCE$ + * $SEEALSO$ + * AADD(),ACOPY(),ADEL(),AEVAL(),AFILL(),ASIZE() + * $INCLUDE$ + * + * $END$ + */ HARBOUR HB_AINS( void ) { @@ -883,6 +1065,44 @@ HARBOUR HB_AINS( void ) hb_itemReturn( pArray ); /* AIns() returns the array itself */ } } +/* $DOC$ + * $FUNCNAME$ + * ADEL() + * $CATEGORY$ + * ARRAY + * $ONELINER$ + * Delete an element form an array. + * $SYNTAX$ + * ADEL(, ) --> aTarget + * $ARGUMENTS$ + * Name of array from which an element is to be removed. + * + * Subcript of the element to be removed. + * $RETURNS$ + * ADEL() Returns an array pointer reference to . + * $DESCRIPTION$ + * This function deletes the element found at subscript + * position in the array .All arrays elements in the array + * below the given subscript position will move up + * one position in the array.In other words,what was formerly the + * sixth subscript position will become the fifth subscript position. + * The lenght of the array will remain unchanged,as the last + * element array become a NIL data type. + * $EXAMPLES$ + * LOCAL aArray + * aArray := { "Harbour","is","Power" } // Result: aArray is + * + * ADEL(aArray, 2) // Result: aArray is + * $TESTS$ + * $STATUS$ + * R + * $COMPLIANCE$ + * $SEEALSO$ + * ACOPY(),AINS(),AFILL() + * $INCLUDE$ + * + * $END$ + */ HARBOUR HB_ADEL( void ) { @@ -896,6 +1116,51 @@ HARBOUR HB_ADEL( void ) hb_itemReturn( pArray ); /* ADel() returns the array itself */ } } +/* $DOC$ + * $FUNCNAME$ + * AFILL() + * $CATEGORY$ + * ARRAY + * $ONELINER$ + * Fill an array with a specified value + * $SYNTAX$ + * AFILL(, , + * [], []) --> aTarget + * $ARGUMENTS$ + * Name of array to be filled. + * + * Expression to be globally filled in + * + * Subscript starting position + * + * Number of subscript to be filled + * $RETURNS$ + * AFILL() returns an array pointer to . + * $DESCRIPTION$ + * This function fill each element of a array named with + * the value .If specified, denotes the beginning + * element to be filled and the array elements will continue to be + * filled for positions. If Not specified, the value of + * will be 1, and the value of will be the value + * of LEN();thus,all subscript positions in the array + * will be filled with the value of . + * This function will work on only a single dimension of . + * If there are array pointer references within a subscript , + * those value will be lost, since this function will overwrite those + * values with new values. + * $EXAMPLES$ + * LOCAL aTest:={Nil,0,1,2} + * Afill(aTest,5) + * $TESTS$ + * $STATUS$ + * R + * $COMPLIANCE$ + * $SEEALSO$ + * AADD(),AEVAL(),DBSTRUCT(),DIRECTORY() + * $INCLUDE$ + * + * $END$ + */ HARBOUR HB_AFILL( void ) { @@ -919,6 +1184,60 @@ HARBOUR HB_AFILL( void ) hb_itemReturn( pArray ); /* AFill() returns the array itself */ } } +/* $DOC$ + * $FUNCNAME$ + * ASCAN() + * $CATEGORY$ + * ARRAY + * $ONELINER$ + * Scan array elements for a specified condition + * $SYNTAX$ + * ASCAN(, , + * [], []) --> nStoppedAt + * $ARGUMENTS$ + * Name of array to be scaned. + * + * Expression to search for withing + * + * Beggining subscript position at witch to start the + * search. + * + * Number of elements to scan with . + * position. If this argument is not specified, all elements from the + * $RETURNS$ + * A numeric value of subscript position where + * was found. + * $DESCRIPTION$ + * This function scan the content of array named for the + * value of . The return value is the position in the + * array in which was found. If it was not + * found, the return value will be 0. + * If specified, the beginnig subscript position at which to start + * scanning may be set with the value passed as . The default + * is 1. + * If specified, the number of array elements to scan may be set with + * the value passed as . The default is the number of elements + * in the array . + * If is a code block, the operation of the function is slighty + * different.Each array subscript pointer reference is passed to the + * code block to be evaluated.The scanning routine will continue until the + * value obtainded from the code block is a logical true (.T.) or until + * the end of the array has been reached. + * $EXAMPLES$ + * aDir:=Directory("*.prg") + * AScan(aDir,,,{|x,y| x[1]="Test.prg"}) + * $TESTS$ + * $STATUS$ + * R + * $COMPLIANCE$ + * This function is not CA-Clipper compatible. Clipper ASCAN() is + * affected by the SET EXACT ON/OFF Condition + * $SEEALSO$ + * ACOMP(),AEVAL() + * $INCLUDE$ + * + * $END$ + */ HARBOUR HB_ASCAN( void ) { @@ -938,57 +1257,50 @@ HARBOUR HB_ASCAN( void ) else hb_retnl( 0 ); } - /* $DOC$ * $FUNCNAME$ - * AEVAL() + * AEVAL() * $CATEGORY$ - * ARRAY + * ARRAY * $ONELINER$ - * Evaluated the subscript element of an array + * Evaluated the subscript element of an array * $SYNTAX$ - * AEVAL(, , + * AEVAL(, , * [], []) --> aArray - * * $ARGUMENTS$ - * Is the array to be evaluated. + * Is the array to be evaluated. * - * Is a code block to evaluate for each element processed. + * Is a code block to evaluate for each element processed. * - * The beggining array element to evaluate. - * - * The number of elements to process. + * The beggining array element to evaluate. * + * The number of elements to process. * $RETURNS$ - * AEVAL() returns an array pointer reference. - * + * AEVAL() returns an array pointer reference. * $DESCRIPTION$ - * This function will evaluate and process the subscript elements - * in . A code block passed as defines the - * operation to be executed on each element of the array. All - * elements in will be evaluated unless specified by a - * beggining subscript position in for elements. + * This function will evaluate and process the subscript elements + * in . A code block passed as defines the + * operation to be executed on each element of the array. All + * elements in will be evaluated unless specified by a + * beggining subscript position in for elements. * - * Two parameters are passed to the code block . The - * individual elements in an array are the first parameter and the - * subscript position is the second. + * Two parameters are passed to the code block . The + * individual elements in an array are the first parameter and the + * subscript position is the second. * - * AEVAL() does not replace a FOR...NEXT loop for processing arrays. - * If a array is an autonomous unit,AEVAL() is appropriate.If the - * array is to be altered or if elements are to be reevalueted, a - * FOR...NEXT loop is more appropriate. + * AEVAL() does not replace a FOR...NEXT loop for processing arrays. + * If a array is an autonomous unit,AEVAL() is appropriate.If the + * array is to be altered or if elements are to be reevalueted, a + * FOR...NEXT loop is more appropriate. * $EXAMPLES$ - * * $TESTS$ - * * $STATUS$ - * R + * R * $COMPLIANCE$ - * * $SEEALSO$ - * EVAL(),DBEVAL() + * EVAL(),DBEVAL() * $INCLUDE$ - * + * * $END$ */ @@ -1012,63 +1324,62 @@ HARBOUR HB_AEVAL( void ) else hb_errRT_BASE( EG_ARG, 2017, NULL, "AEVAL" ); } - /* $DOC$ * $FUNCNAME$ - * ACOPY() + * ACOPY() * $CATEGORY$ - * ARRAY + * ARRAY * $ONELINER$ - * Copy elements from one array to another + * Copy elements from one array to another * $SYNTAX$ - * ACOPY(, , + * ACOPY(, , * [], [], []) --> aTarget - * * $ARGUMENTS$ - * is the array to copy elements from. + * is the array to copy elements from. * - * is the array to copy elements to. + * is the array to copy elements to. * - * is the beggining subscript position to copy from + * is the beggining subscript position to copy from * - * the number of subscript elements to copy from - * - * the starting subscript position in to copy - * elements to + * the number of subscript elements to copy from . * + * the starting subscript position in to copy + * elements to. * $RETURNS$ - * ACOPY() returns an array pointer reference + * ACOPY() returns an array pointer reference * $DESCRIPTION$ - * This function copies array elements from to . - * is the beggining element to be copied from ;the - * default is 1. - * is the number of element to be copied from ;the - * default is the entire array. - * is the subscript number in the target array,, - * to witch array elements are to be copied;the default is 1 - * This function will copy all data types in to . - * If an array element in is a pointer reference to another - * array, that array pointer will be copied to ; not all - * subdimensions will be copied from one array to the next. This must - * be accomplished via the ACLONE() function. + * This function copies array elements from to . + * is the beggining element to be copied from ;the + * default is 1. + * is the number of element to be copied from ;the + * default is the entire array. + * is the subscript number in the target array,, + * to witch array elements are to be copied;the default is 1 + * This function will copy all data types in to . + * If an array element in is a pointer reference to another + * array, that array pointer will be copied to ; not all + * subdimensions will be copied from one array to the next. This must + * be accomplished via the ACLONE() function. * - * ^b note - * If array is larger then , array elements will - * start copying at and continue copying until the end of - * array is reached. The ACOPY() function doesn't append - * subscript positions to the target array, the size of the target - * array remains constant. + * Note + * If array is larger then , array elements will + * start copying at and continue copying until the end of + * array is reached. The ACOPY() function doesn't append + * subscript positions to the target array, the size of the target + * array remains constant. * $EXAMPLES$ + * LOCAL nCount := 2, nStart := 1, aOne, aTwo + * aOne := {"HABOUR"," is ","POWER"} + * aTwo := {"CLIPPER"," was ","POWER"} + * ACOPY(aOne, aTwo, nStart, nCount) * $TESTS$ - * * $STATUS$ - * R + * R * $COMPLIANCE$ - * * $SEEALSO$ - * ACLONE(),ADEL(),AEVAL(),AFILL(),AINS(),ASORT() + * ACLONE(),ADEL(),AEVAL(),AFILL(),AINS(),ASORT() * $INCLUDE$ - * + * * $END$ */ @@ -1097,37 +1408,45 @@ HARBOUR HB_ACOPY( void ) } } -/* NOTE: Clipper will return NIL if the parameter is not an array. [vszel] */ +/* NOTE: [vszel] */ /* $DOC$ * $FUNCNAME$ - * ACLONE() + * ACLONE() * $CATEGORY$ - * ARRAY + * ARRAY * $ONELINER$ - * Duplicate a multidimensional array + * Duplicate a multidimensional array * $SYNTAX$ - * ACLONE() --> aDuplicate + * ACLONE() --> aDuplicate * $ARGUMENTS$ - * Name of the array to be cloned. + * Name of the array to be cloned. * $RETURNS$ - * ACLONE() A new array pointer reference complete with nested array - * values. + * ACLONE() A new array pointer reference complete with nested array + * values. * $DESCRIPTION$ - * This function makes a complete copy of the array expressed as - * and return a cloned set of array values.This provides - * a complete + * This function makes a complete copy of the array expressed as + * and return a cloned set of array values.This provides + * a complete * $EXAMPLES$ + * This example creates an array then duplicates it using + * ACLONE(). The first array is then altered, but the duplicate copy is + * unaffected: + * + * LOCAL aOne, aTwo + * aOne := {"Harbour"," is ","POWER"} + * aTwo := ACLONE(aOne) // Result: aTwo is {1, 2, 3} + * aOne[1] := "The Harbour Compiler" // Result: aOne is {99, 2, 3} + * // aTwo is still {1, 2, 3} * $TESTS$ - * * $STATUS$ - * R + * R * $COMPLIANCE$ - * NOTE: Clipper will return NIL if the parameter is not an array. + * Clipper will return NIL if the parameter is not an array. * $SEEALSO$ - * ACOPY(),ADEL(),AINS(),ASIZE() + * ACOPY(),ADEL(),AINS(),ASIZE() * $INCLUDE$ - * + * * $END$ */ @@ -1142,3 +1461,4 @@ HARBOUR HB_ACLONE( void ) hb_itemRelease( pDstArray ); } } + diff --git a/harbour/source/rtl/objfunc.prg b/harbour/source/rtl/objfunc.prg index dd52671294..e986c80d60 100644 --- a/harbour/source/rtl/objfunc.prg +++ b/harbour/source/rtl/objfunc.prg @@ -184,7 +184,7 @@ return __objHasMsg( oObject, cSymbol ) .and. ; * $PLATFORMS$ * $FILES$ * $SEEALSO$ - * __ObjGetMethodList(),__ObjGetValueList,__objHasData(),__objHasMethod() + * __ObjGetMethodList(),__ObjGetValueList(),__objHasData(),__objHasMethod() * $END$ */ @@ -569,7 +569,7 @@ return oObject * $PLATFORMS$ * $FILES$ * $SEEALSO$ - * __objAddInline(),__objAddMethod(),__objDelData(),__objGetMsgList(),__ObjGetValueList(),__objHasData() ,__ObjSetValueList() + * __objAddInline(),__objAddMethod(),__objDelData(),__objGetMsgList(),__ObjGetValueList(),__objHasData(),__ObjSetValueList() * $END$ */ diff --git a/harbour/source/tools/fileread.prg b/harbour/source/tools/fileread.prg index 0552bc819a..7689e0f4e7 100644 --- a/harbour/source/tools/fileread.prg +++ b/harbour/source/tools/fileread.prg @@ -120,7 +120,7 @@ * $COMPLIANCE$ * This is a new Harbour Tools class * $SEEALSO$ - * TClass + * TClass() * $END$ */ diff --git a/harbour/source/tools/nconvert.prg b/harbour/source/tools/nconvert.prg index 7a562b9b14..a156a3192f 100644 --- a/harbour/source/tools/nconvert.prg +++ b/harbour/source/tools/nconvert.prg @@ -36,26 +36,22 @@ /* $DOC$ * $FUNCNAME$ * ISBIN() - * * $CATEGORY$ * Conversion * $ONELINER$ * Check if the value is a Binary Number * $SYNTAX$ * ISBIN() -> - * * $ARGUMENTS$ * STRING TO BE CHECKED * $RETURNS$ - * - * ^b .T.^b IF THE STRING IS BYNARY - * ^b .F.^b^ IF NOT + * .T. IF THE STRING IS BYNARY + * .F. IF NOT * $DESCRIPTION$ - * ^b check if the passed string is a bynary number or not + * check if the passed string is a bynary number or not * $EXAMPLES$ - * * $SEEALSO$ - * ISOCTAL(), ISDEC(), ISHEXA() + * ISOCTAL(),ISDEC(),ISHEXA() * $INCLUDE$ * * $END$ @@ -75,27 +71,22 @@ FUNCTION IsBin(cString) /* $DOC$ * $FUNCNAME$ * ISOCTAL() - * * $CATEGORY$ * Conversion * $ONELINER$ * Check if the value is a Octal Number * $SYNTAX$ * ISOCTAL() -> - * * $ARGUMENTS$ * STRING TO BE CHECKED * $RETURNS$ - * - * ^b .T.^b IF THE STRING IS OCTAL - * ^b .F.^b^ IF NOT - * + * .T. IF THE STRING IS OCTAL + * .F. IF NOT * $DESCRIPTION$ - * ^b check if the passed string is a octal number or not + * check if the passed string is a octal number or not * $EXAMPLES$ - * * $SEEALSO$ - * ISBIN(), ISDEC(), ISHEXA() + * ISBIN(),ISDEC(),ISHEXA() * $INCLUDE$ * * $END$ @@ -115,25 +106,22 @@ FUNCTION IsOctal(cString) /* $DOC$ * $FUNCNAME$ * ISDEC() - * * $CATEGORY$ * Conversion * $ONELINER$ * Check if the value is a Decimal Number * $SYNTAX$ * ISDEC() -> - * * $ARGUMENTS$ * STRING TO BE CHECKED * $RETURNS$ - * ^b .T.^b IF THE STRING IS DECIMAL - * ^b .F.^b^ IF NOT + * .T. IF THE STRING IS DECIMAL + * .F. IF NOT * $DESCRIPTION$ - * ^b check if the passed string is a decimal number or not + * check if the passed string is a decimal number or not * $EXAMPLES$ - * * $SEEALSO$ - * ISOCTAL(), ISBIN(), ISHEXA() + * ISOCTAL(),ISBIN(),ISHEXA() * $INCLUDE$ * * $END$ @@ -153,25 +141,22 @@ FUNCTION IsDec(cString) /* $DOC$ * $FUNCNAME$ * ISHEXA() - * * $CATEGORY$ * Conversion * $ONELINER$ * Check if the value is a Hexal Number * $SYNTAX$ * ISHEXA() -> - * * $ARGUMENTS$ * STRING TO BE CHECKED * $RETURNS$ - * ^b .T.^b IF THE STRING IS HEXA - * ^b .F.^b^ IF NOT + * .T. IF THE STRING IS HEXA + * .F. IF NOT * $DESCRIPTION$ - * ^b check if the passed string is a hexa number or not + * check if the passed string is a hexa number or not * $EXAMPLES$ - * * $SEEALSO$ - * ISOCTAL(), ISDEC(), ISBIN() + * ISOCTAL(),ISDEC(),ISBIN() * $INCLUDE$ * * $END$ @@ -191,24 +176,23 @@ FUNCTION IsHexa(cString) /* $DOC$ * $FUNCNAME$ * DECTOBIN() - * * $CATEGORY$ * Conversion * $ONELINER$ * Converts a Decimal Value to Binary * $SYNTAX$ * DECTOBIN() -> - * * $ARGUMENTS$ * NUMBER TO BE CONVERTED * $RETURNS$ * NUMBER CONVERTED * $DESCRIPTION$ - * + * This function converts a string from an decimal value + * to an binary value. * $EXAMPLES$ * * $SEEALSO$ - * + * Dectohexa(),dectooctal() * $INCLUDE$ * * $END$ @@ -227,24 +211,23 @@ FUNCTION DecToBin(nNumber) /* $DOC$ * $FUNCNAME$ * DECTOOCTAL() - * * $CATEGORY$ * Conversion * $ONELINER$ * Converts a Decimal Value to Octal * $SYNTAX$ * DECTOOCTAL() -> - * * $ARGUMENTS$ * NUMBER TO BE CONVERTED * $RETURNS$ * NUMBER CONVERTED * $DESCRIPTION$ - * + * This function converts a string from an decimal value + * to an octal value. * $EXAMPLES$ * * $SEEALSO$ - * + * Dectohexa(),dectobin() * $INCLUDE$ * * $END$ @@ -263,24 +246,23 @@ FUNCTION DecToOctal(nNumber) /* $DOC$ * $FUNCNAME$ * DECTOHEXA() - * * $CATEGORY$ * Conversion * $ONELINER$ * Converts a Decimal Value to Hexa * $SYNTAX$ * DECTOHEXA() -> - * * $ARGUMENTS$ * NUMBER TO BE CONVERTED * $RETURNS$ * NUMBER CONVERTED * $DESCRIPTION$ - * + * This function converts a string from an decimal value + * to an hexadecimal value. * $EXAMPLES$ * * $SEEALSO$ - * + * Dectobin(),dectoctal() * $INCLUDE$ * * $END$ @@ -299,24 +281,23 @@ FUNCTION DecToHexa(nNumber) /* $DOC$ * $FUNCNAME$ * BIntODEC() - * * $CATEGORY$ * Conversion * $ONELINER$ * Converts a Binary Value to Decimal * $SYNTAX$ * BIntODEC() -> - * * $ARGUMENTS$ * NUMBER TO BE CONVERTED * $RETURNS$ * NUMBER CONVERTED * $DESCRIPTION$ - * + * This function converts a string from an binary value + * to a numeric decimal value. * $EXAMPLES$ * * $SEEALSO$ - * + * OctaltoDec(),HexatoDec() * $INCLUDE$ * * $END$ @@ -335,24 +316,23 @@ FUNCTION BinToDec(cString) /* $DOC$ * $FUNCNAME$ * OCTALTODEC() - * * $CATEGORY$ * Conversion * $ONELINER$ * Converts a Octal Value to Decimal * $SYNTAX$ * OCTALTODEC() -> - * * $ARGUMENTS$ * NUMBER TO BE CONVERTED * $RETURNS$ * NUMBER CONVERTED * $DESCRIPTION$ - * + * This function converts a string from an octal value + * to a numeric decimal value. * $EXAMPLES$ * * $SEEALSO$ - * + * BintoDec(),HexatoDec() * $INCLUDE$ * * $END$ @@ -371,29 +351,29 @@ FUNCTION OctalToDec(cString) /* $DOC$ * $FUNCNAME$ - * HEXATODEC() + * HEXATODEC() * $CATEGORY$ * Conversion * $ONELINER$ - * Converts a Hexa Value to Decimal + * Converts a Hexa Value to Decimal * $SYNTAX$ - * HEXATODEC() -> - * + * HEXATODEC() -> * $ARGUMENTS$ - * NUMBER TO BE CONVERTED + * NUMBER TO BE CONVERTED * $RETURNS$ - * NUMBER CONVERTED + * NUMBER CONVERTED * $DESCRIPTION$ - * + * This function converts a string from an hexadecimal value + * to a numeric decimal value. * $EXAMPLES$ * * $SEEALSO$ - * + * OctaltoDec(),BintoDec() * $INCLUDE$ * * $END$ */ - + FUNCTION HexaToDec(cString) local nNumber:=0,nX:=0 local cNewString:=AllTrim(cString) @@ -404,4 +384,4 @@ FUNCTION HexaToDec(cString) NEXT nX RETURN nNumber -* EOF: NCONVERT.PRG + diff --git a/harbour/source/tools/ng.prg b/harbour/source/tools/ng.prg index f112e419dd..11ed82b944 100644 --- a/harbour/source/tools/ng.prg +++ b/harbour/source/tools/ng.prg @@ -66,14 +66,14 @@ RETURN Self METHOD WritePar( cPar ) CLASS TNortonGuide - FWRITE( Self:nHandle, ALLTRIM( cPar ) + CRLF ) + FWRITE( Self:nHandle, HB_OEMTOANSI( cPar ) + CRLF ) RETURN Self METHOD WriteParBold( cPar ) CLASS TNortonGuide - - FWRITE( Self:nHandle, '^b' + ALLTRIM( cPar ) + '^b^' + CRLF ) - + Self:WritePar("") + FWRITE( Self:nHandle, '^b' + HB_OEMTOANSI( cPar ) + '^b^' + CRLF ) + Self:WritePar("") RETURN Self METHOD WriteTitle( cTopic, cTitle ) CLASS TNortonGuide @@ -82,7 +82,7 @@ METHOD WriteTitle( cTopic, cTitle ) CLASS TNortonGuide LOCAL nPos LOCAL cWrite - cTopic := ALLTRIM( cTopic ) + cTopic := HB_OEMTOANSI( cTopic ) FWRITE( Self:nHandle, "!Short: " + cTopic + CRLF ) @@ -140,9 +140,7 @@ RETURN Self * oNg:WritePar( "See the Links Above" ) * oNg:Close() * RETURN Nil - * * $TESTS$ - * * $STATUS$ * R * $COMPLIANCE$ @@ -150,7 +148,6 @@ RETURN Self * $PLATFORMS$ * ALL * $FILES$ - * * $SEEALSO$ * TCLASS() * $END$ diff --git a/harbour/source/tools/os2.prg b/harbour/source/tools/os2.prg index c5e14e8c62..e77b57b1c6 100644 --- a/harbour/source/tools/os2.prg +++ b/harbour/source/tools/os2.prg @@ -77,7 +77,7 @@ RETURN Self METHOD WritePar( cPar ) CLASS TOs2 - FWRITE( Self:nHandle, ".br"+CRLF+Self:DostoOs2Text(ALLTRIM( cPar )) + CRLF ) + FWRITE( Self:nHandle, ".br"+CRLF+Self:DostoOs2Text( cPar ) + CRLF ) RETURN Self @@ -100,9 +100,6 @@ METHOD WriteTitle( cTopic, cTitle ) CLASS TOs2 ELSE // Just in case that nItem>0 so the Link is already referenced nItem:=ASCAN(Self:aLinkRef,{|a| a[1]==cTopic}) ENDIF - // IF nItem==0 - // nItem:=Self:nRef - // ENDIF fWrite(Self:nHandle,':title.'+ALLTRIM(cTitle)+CRLF) diff --git a/harbour/source/tools/rtf.prg b/harbour/source/tools/rtf.prg index b3ca13465f..e99c94fca0 100644 --- a/harbour/source/tools/rtf.prg +++ b/harbour/source/tools/rtf.prg @@ -111,8 +111,9 @@ METHOD WriteHeader() CLASS TRTF RETURN Self METHOD WritePar( cPar ) CLASS TRTF - - FWRITE( Self:nHandle, '\pard{\cf1\fs20 ' + ALLTRIM( cPar ) ) + cPar:=StrTran(cPar,"{","\{") + cPar:=StrTran(cPar,"}","\}") + FWRITE( Self:nHandle, '\pard{\cf1\fs30 ' + HB_OEMTOANSI(" ")+ HB_OEMTOANSI(cPar )) RETURN Self METHOD EndPar() CLASS TRTF @@ -123,8 +124,9 @@ RETURN Self METHOD WriteParBold( cPar ) CLASS TRTF - FWRITE( Self:nHandle, '\pard{\plain\cf1\f2\fs20\i\b\qc ' + ALLTRIM( cPar ) + ' }\par' + CRLF ) - + cPar:=StrTran(cPar,"{","\{") + cPar:=StrTran(cPar,"}","\}") + FWRITE( Self:nHandle, '\pard{\plain\cf1\f2\fs30\i\b\qc ' + ALLTRIM(HB_OEMTOANSI( cPar )) + ' }\par' + CRLF ) RETURN Self METHOD WriteTitle( cTitle, cTopic ) CLASS TRTF @@ -136,12 +138,13 @@ METHOD WriteTitle( cTitle, cTopic ) CLASS TRTF nPos := AT( "()", cTitle ) IF nPos > 0 - cTemp := ALLTRIM( STRTRAN( cTitle, "()", "xx" ) ) + cTemp := ALLTRIM( HB_OEMTOANSI(STRTRAN( cTitle, "()", "xx" ) )) ELSE - cTemp := ALLTRIM( cTitle ) + cTemp := HB_OEMTOANSI(ALLTRIM( cTitle )) + cTemp :=STRTRAN( cTemp,"@", "x" ) ENDIF - cTopic := ALLTRIM( cTopic ) + cTopic := ALLTRIM( HB_OEMTOANSI(cTopic )) cWrite := '{\f2' + CRLF + ; ' #{\footnote \pard\plain \fs20 # ' + "IDH_"+cTemp + ' }' + CRLF + ; @@ -151,7 +154,7 @@ METHOD WriteTitle( cTitle, cTopic ) CLASS TRTF FWRITE( Self:nHandle, cWrite ) - Self:WritePar( cTopic ):EndPar() + Self:WriteParBold( cTopic ) RETURN Self @@ -167,7 +170,7 @@ RETURN Self METHOD WriteLink( cLink ) CLASS TRTF - FWRITE( Self:nHandle, '\pard{\cf1\fs20 {\f2\uldb ' + ALLTRIM( cLink ) + '}{\v\f2 ' + "IDH_"+ALLTRIM( STRTRAN( cLink, "()", "xx" ) ) + '} }\par' + CRLF ) + FWRITE( Self:nHandle, '\pard{\cf1\fs30 {\f2\uldb ' + ALLTRIM( HB_OEMTOANSI(cLink) ) + '}{\v\f2 ' + "IDH_"+IF(AT( "()",cLink)>0 , ALLTRIM( HB_OEMTOANSI(STRTRAN( cLink, "()", "xx" ) )),ALLTRIM( HB_OEMTOANSI(STRTRAN( cLink, "@", "x" )) )) + '} }\par' + CRLF ) RETURN Self diff --git a/harbour/source/tools/troff.prg b/harbour/source/tools/troff.prg index 44432f44c3..967bb420bd 100644 --- a/harbour/source/tools/troff.prg +++ b/harbour/source/tools/troff.prg @@ -48,7 +48,6 @@ CLASS TTROFF DATA cFile DATA nHandle METHOD New( cFile ) - METHOD WritePar( cPar ) METHOD WriteLink( clink ) METHOD CLOSE() @@ -138,3 +137,57 @@ METHOD WriteLink( cLink ) CLASS TTROFF RETURN Self *+ EOF: TROFF.PRG +*+ EOF: RTF.PRG +/* $DOC$ + * $FUNCNAME$ + * TTroff() + * $CATEGORY$ + * Harbour Tools + * $ONELINER$ + * Troff Class + * $SYNTAX$ + * oTroff:=TTrof():New() + * $ARGUMENTS$ + * Name of the RTF file to create + * $RETURNS$ + * An instance of the TTroff Class + * $DESCRIPTION$ + * TRtf() is a class that create the Norton Guide Source + * Code of the same name you pass to the constructor. + * The class methods are as follows: + * New() Create a new instance of the THtml class. + * Close() Close the create file + * WriteTitle(,) Write the file title + * WritePar() Writes a paragrafer + * WriteParBold() Same as WritePar(), but the text is bold style. + * WriteLink() Write a link to another topic + * WriteText() Writes a text with out formating + * $EXAMPLES$ + * FUNCTION MAIN() + * + * LOCAL oTroff + * oTroff := TTroff():New( "tr\harbour.ngi" ) + * oTroff:WriteTitle( "Harbour Reference Guide" ) + * oTroff:WritePar( "HARBOUR" ) + * oTroff:WriteLink( "OverView" ) + * oTroff:WriteLink( "License" ) + * + * oTroff:WritePar( "See the Links Above" ) + * oTroff:Close() + * + * RETURN Nil + * + * $TESTS$ + * + * $STATUS$ + * R + * $COMPLIANCE$ + * This is a new Harbour Tools class + * $PLATFORMS$ + * ALL + * $FILES$ + * + * $SEEALSO$ + * TCLASS() + * $END$ + */