2012-07-03 22:25 UTC+0200 Viktor Szakats (harbour syenar.net)
* doc/en/memvar2.txt
* doc/en/menu.txt
* doc/en/misc.txt
* doc/en/nation.txt
* doc/en/objfunc.txt
* doc/en/rdddb.txt
* doc/en/rddmisc.txt
* doc/en/rddord.txt
* doc/en/sayget.txt
* doc/en/set.txt
* doc/en/string.txt
* doc/en/tbrowse.txt
* doc/en/tclass.txt
* doc/en/terminal.txt
* doc/en/tgetlist.txt
* doc/en/tlabel.txt
* doc/en/treport.txt
* doc/en/var.txt
! further fixes in $EXAMPLES$ sections
This commit is contained in:
@@ -16,6 +16,27 @@
|
||||
The license applies to all entries newer than 2009-04-28.
|
||||
*/
|
||||
|
||||
2012-07-03 22:25 UTC+0200 Viktor Szakats (harbour syenar.net)
|
||||
* doc/en/memvar2.txt
|
||||
* doc/en/menu.txt
|
||||
* doc/en/misc.txt
|
||||
* doc/en/nation.txt
|
||||
* doc/en/objfunc.txt
|
||||
* doc/en/rdddb.txt
|
||||
* doc/en/rddmisc.txt
|
||||
* doc/en/rddord.txt
|
||||
* doc/en/sayget.txt
|
||||
* doc/en/set.txt
|
||||
* doc/en/string.txt
|
||||
* doc/en/tbrowse.txt
|
||||
* doc/en/tclass.txt
|
||||
* doc/en/terminal.txt
|
||||
* doc/en/tgetlist.txt
|
||||
* doc/en/tlabel.txt
|
||||
* doc/en/treport.txt
|
||||
* doc/en/var.txt
|
||||
! further fixes in $EXAMPLES$ sections
|
||||
|
||||
2012-07-03 13:14 UTC+0200 Viktor Szakats (harbour syenar.net)
|
||||
* doc/en/command.txt
|
||||
* doc/en/datetime.txt
|
||||
@@ -49,7 +70,7 @@
|
||||
* doc/en/misc.txt
|
||||
* doc/en/string.txt
|
||||
* doc/en/var.txt
|
||||
* fixes
|
||||
* fixes in $EXAMPLES$ sections
|
||||
|
||||
* doc/en/*.txt
|
||||
* set mime-type to UTF-8
|
||||
|
||||
@@ -32,14 +32,14 @@
|
||||
* has no effect on memory variables or on field reference buried within
|
||||
* a macro expression.
|
||||
* $EXAMPLES$
|
||||
* Func main
|
||||
* FIELD iD
|
||||
* FIELD Name
|
||||
* USE TESTS NEW
|
||||
* name:="Sales"
|
||||
* Id:=5
|
||||
* USE
|
||||
* Return Nil
|
||||
* PROCEDURE Main()
|
||||
* FIELD Id
|
||||
* FIELD Name
|
||||
* USE tests NEW
|
||||
* Name := "Sales"
|
||||
* Id := 5
|
||||
* USE
|
||||
* RETURN
|
||||
* $TESTS$
|
||||
* See tests/testwarn.prg
|
||||
* $STATUS$
|
||||
@@ -97,15 +97,15 @@
|
||||
*
|
||||
* LOCAL variables and arrays are not affected by the RELEASE command.
|
||||
* $EXAMPLES$
|
||||
* Function Main2()
|
||||
* Local n, lVar
|
||||
* PROCEDURE Main()
|
||||
* LOCAL n, lVar
|
||||
*
|
||||
* n := IIF( lVar, "A", 3 )
|
||||
* n := 2
|
||||
* n := "a"
|
||||
* n := seconds() + 2
|
||||
* n := int( seconds() + 2 )
|
||||
* Return NIL
|
||||
* n := iif( lVar, "A", 3 )
|
||||
* n := 2
|
||||
* n := "a"
|
||||
* n := seconds() + 2
|
||||
* n := int( seconds() + 2 )
|
||||
* RETURN
|
||||
* $TESTS$
|
||||
* See tests/testwarn.prg for more examples
|
||||
* $STATUS$
|
||||
@@ -148,18 +148,18 @@
|
||||
* is similat to the LOCAL,STATIC,FIELD,PARAMETERS,FUNCTION, and
|
||||
* PROCEDURE commands statements.
|
||||
* $EXAMPLES$
|
||||
* MEMVAR y As Numeric
|
||||
* Function Main2()
|
||||
* Local n , lVar
|
||||
* MEMVAR y AS NUMERIC
|
||||
* PROCEDURE Main()
|
||||
* LOCAL n, lVar
|
||||
*
|
||||
* n := IIF( lVar, "A", 3 )
|
||||
* n := 2
|
||||
* n := "a"
|
||||
* n := seconds() + 2
|
||||
* n := int( seconds() + 2 )
|
||||
* y := n
|
||||
* ? y
|
||||
* Return NIL
|
||||
* n := iif( lVar, "A", 3 )
|
||||
* n := 2
|
||||
* n := "a"
|
||||
* n := seconds() + 2
|
||||
* n := int( seconds() + 2 )
|
||||
* y := n
|
||||
* ? y
|
||||
* RETURN
|
||||
* $TESTS$
|
||||
* See tests/testwarn.prg for more examples
|
||||
* $STATUS$
|
||||
|
||||
@@ -82,10 +82,10 @@
|
||||
* aItems := { "One", "Two", "Three" }
|
||||
* nChoice := ACHOICE( 10, 10, 20, 20, aItems )
|
||||
* IF nChoice == 0
|
||||
* ? "You did not choose an item"
|
||||
* ? "You did not choose an item"
|
||||
* ELSE
|
||||
* ? "You chose element " + LTRIM( STR( nChoice ) )
|
||||
* ?? " which has a value of " + aItems[ nChoice ]
|
||||
* ? "You chose element " + hb_ntos( nChoice )
|
||||
* ?? " which has a value of " + aItems[ nChoice ]
|
||||
* ENDIF
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
@@ -143,12 +143,12 @@
|
||||
* @ 11, 2 PROMPT "Monday" MESSAGE "Now we're on the 2nd item"
|
||||
* MENU TO nChoice
|
||||
* DO CASE
|
||||
* CASE nChoice == 0 // user press Esc key
|
||||
* QUIT
|
||||
* CASE nChoice == 1 // user select 1st menu item
|
||||
* ? "Guess you don't like Mondays"
|
||||
* CASE nChoice == 2 // user select 2nd menu item
|
||||
* ? "Just another day for some"
|
||||
* CASE nChoice == 0 // user press Esc key
|
||||
* QUIT
|
||||
* CASE nChoice == 1 // user select 1st menu item
|
||||
* ? "Guess you don't like Mondays"
|
||||
* CASE nChoice == 2 // user select 2nd menu item
|
||||
* ? "Just another day for some"
|
||||
* ENDCASE
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -206,12 +206,12 @@
|
||||
* @ 11, 2 PROMPT "Monday" MESSAGE "Now we're on the 2nd item"
|
||||
* MENU TO nChoice
|
||||
* DO CASE
|
||||
* CASE nChoice == 0 // user press Esc key
|
||||
* QUIT
|
||||
* CASE nChoice == 1 // user select 1st menu item
|
||||
* ? "Guess you don't like Mondays"
|
||||
* CASE nChoice == 2 // user select 2nd menu item
|
||||
* ? "Just another day for some"
|
||||
* CASE nChoice == 0 // user press Esc key
|
||||
* QUIT
|
||||
* CASE nChoice == 1 // user select 1st menu item
|
||||
* ? "Guess you don't like Mondays"
|
||||
* CASE nChoice == 2 // user select 2nd menu item
|
||||
* ? "Just another day for some"
|
||||
* ENDCASE
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -290,19 +290,19 @@
|
||||
* $EXAMPLES$
|
||||
* // display menu item on each screen corner and let user select one
|
||||
* CLS
|
||||
* SET MESSAGE TO MAXROW()/2 CENTER
|
||||
* SET MESSAGE TO MAXROW() / 2 CENTER
|
||||
* SET WRAP ON
|
||||
* @ 0, 0 PROMPT "1. Upper left" MESSAGE " One "
|
||||
* @ 0, MAXCOL()-16 PROMPT "2. Upper right" MESSAGE " Two "
|
||||
* @ MAXROW()-1,MAXCOL()-16 PROMPT "3. Bottom right" MESSAGE "Three"
|
||||
* @ MAXROW()-1,0 PROMPT "4. Bottom left" MESSAGE "Four "
|
||||
* @ 0 , 0 PROMPT "1. Upper left" MESSAGE " One "
|
||||
* @ 0 , MAXCOL()-16 PROMPT "2. Upper right" MESSAGE " Two "
|
||||
* @ MAXROW() - 1, MAXCOL()-16 PROMPT "3. Bottom right" MESSAGE "Three"
|
||||
* @ MAXROW() - 1, 0 PROMPT "4. Bottom left" MESSAGE "Four "
|
||||
* MENU TO nChoice
|
||||
* SETPOS ( MAXROW()/2, MAXCOL()/2 - 10 )
|
||||
* if nChoice == 0
|
||||
* SETPOS( MAXROW() / 2, MAXCOL() / 2 - 10 )
|
||||
* IF nChoice == 0
|
||||
* ?? "Esc was pressed"
|
||||
* else
|
||||
* ELSE
|
||||
* ?? "Selected option is", nChoice
|
||||
* endif
|
||||
* ENDIF
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -376,19 +376,19 @@
|
||||
* $EXAMPLES$
|
||||
* // display menu item on each screen corner and let user select one
|
||||
* CLS
|
||||
* SET MESSAGE TO MAXROW()/2 CENTER
|
||||
* SET MESSAGE TO MAXROW() / 2 CENTER
|
||||
* SET WRAP ON
|
||||
* @ 0, 0 PROMPT "1. Upper left" MESSAGE " One "
|
||||
* @ 0, MAXCOL()-16 PROMPT "2. Upper right" MESSAGE " Two "
|
||||
* @ MAXROW()-1,MAXCOL()-16 PROMPT "3. Bottom right" MESSAGE "Three"
|
||||
* @ MAXROW()-1,0 PROMPT "4. Bottom left" MESSAGE "Four "
|
||||
* @ 0 , 0 PROMPT "1. Upper left" MESSAGE " One "
|
||||
* @ 0 , MAXCOL() - 16 PROMPT "2. Upper right" MESSAGE " Two "
|
||||
* @ MAXROW() - 1, MAXCOL() - 16 PROMPT "3. Bottom right" MESSAGE "Three"
|
||||
* @ MAXROW() - 1, 0 PROMPT "4. Bottom left" MESSAGE "Four "
|
||||
* MENU TO nChoice
|
||||
* SETPOS ( MAXROW()/2, MAXCOL()/2 - 10 )
|
||||
* if nChoice == 0
|
||||
* SETPOS( MAXROW() / 2, MAXCOL() / 2 - 10 )
|
||||
* IF nChoice == 0
|
||||
* ?? "Esc was pressed"
|
||||
* else
|
||||
* ELSE
|
||||
* ?? "Selected option is", nChoice
|
||||
* endif
|
||||
* ENDIF
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -65,8 +65,7 @@
|
||||
* $DESCRIPTION$
|
||||
* This function returns the current Harbour Version.
|
||||
* $EXAMPLES$
|
||||
* ? QOUT(VERSION())
|
||||
* "Harbour Terminal: Standard stream console"
|
||||
* ? VERSION() // "Harbour Terminal: Standard stream console"
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -108,9 +107,9 @@
|
||||
* If no environment variable
|
||||
* is found, an empty string is returned.
|
||||
* $EXAMPLES$
|
||||
* ? QOUT(GETENV("PATH"))
|
||||
* ? QOUT(GETENV("CONFIG"))
|
||||
* ? QOUT(GETENV("HARBOURCMD", "-n -l -es2"))
|
||||
* ? GETENV( "PATH" )
|
||||
* ? GETENV( "CONFIG" )
|
||||
* ? GETENV( "HARBOURCMD", "-n -l -es2" )
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -152,9 +151,9 @@
|
||||
* If no environment variable
|
||||
* is found, an empty string is returned.
|
||||
* $EXAMPLES$
|
||||
* ? QOUT(GETE("PATH"))
|
||||
* ? QOUT(GETE("CONFIG"))
|
||||
* ? QOUT(GETE("HARBOURCMD", "-n -l -es2"))
|
||||
* ? GETE( "PATH" )
|
||||
* ? GETE( "CONFIG" )
|
||||
* ? GETE( "HARBOURCMD", "-n -l -es2" )
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -208,9 +207,9 @@
|
||||
* can be found, the value of the function will be <cDefaultValue>
|
||||
* if it is passed, else an empty string.
|
||||
* $EXAMPLES$
|
||||
* ? QOUT(HB_GETENV("PATH"))
|
||||
* ? QOUT(HB_GETENV("CONFIG"))
|
||||
* ? QOUT(HB_GETENV("HARBOURCMD", "-n -l -es2"))
|
||||
* ? HB_GETENV( "PATH" )
|
||||
* ? HB_GETENV( "CONFIG" )
|
||||
* ? HB_GETENV( "HARBOURCMD", "-n -l -es2" )
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -252,8 +251,8 @@
|
||||
* It is considered bad form to use this function directly.
|
||||
* Use the RUN command instead.
|
||||
* $EXAMPLES$
|
||||
* __Run( "edit " + cMyTextFile ) // Runs an external editor
|
||||
* __Run( "command" ) // Gives a DOS shell (DOS only)
|
||||
* __run( "edit " + cMyTextFile ) // Runs an external editor
|
||||
* __run( "command" ) // Gives a DOS shell (DOS only)
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -296,15 +295,15 @@
|
||||
* user, his or her dog, and the surrounding neighborhood. The frequency
|
||||
* is limited to the range 0 to 32767 Hz.
|
||||
* $EXAMPLES$
|
||||
* If lOk // Good Sound
|
||||
* IF lOk // Good Sound
|
||||
* TONE( 500, 1 )
|
||||
* TONE( 4000, 1 )
|
||||
* TONE( 2500, 1 )
|
||||
* Else // Bad Sound
|
||||
* ELSE // Bad Sound
|
||||
* TONE( 300, 1 )
|
||||
* TONE( 499, 5 )
|
||||
* TONE( 700, 5 )
|
||||
* EndIf
|
||||
* ENDIF
|
||||
* $TESTS$
|
||||
* TONE( 800, 1 ) // same as ? CHR(7)
|
||||
* TONE( 32000, 200 ) // any dogs around yet?
|
||||
@@ -348,8 +347,8 @@
|
||||
* Do not use it to run Terminate and Stay Resident programs
|
||||
* (in case of DOS) since that causes several problems.
|
||||
* $EXAMPLES$
|
||||
* Run "edit " + cMyTextFile // Runs an external editor
|
||||
* Run "command" // Gives a DOS shell (DOS only)
|
||||
* RUN ( "edit " + cMyTextFile ) // Runs an external editor
|
||||
* RUN command // Gives a DOS shell (DOS only)
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
|
||||
@@ -38,9 +38,9 @@
|
||||
* according to the msgxxx module used. </par>
|
||||
* $EXAMPLES$
|
||||
* // Wait until user enters Y
|
||||
* DO WHILE !ISAFFIRM( cYesNo )
|
||||
* ACCEPT "Sure: " TO cYesNo
|
||||
* END DO
|
||||
* DO WHILE ! ISAFFIRM( cYesNo )
|
||||
* ACCEPT "Sure: " TO cYesNo
|
||||
* ENDDO
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -75,9 +75,9 @@
|
||||
* according to the msgxxx module used. </par>
|
||||
* $EXAMPLES$
|
||||
* // Wait until user enters N
|
||||
* DO WHILE !ISNEGATIVE( cYesNo )
|
||||
* ACCEPT "Sure: " TO cYesNo
|
||||
* END DO
|
||||
* DO WHILE ! ISNEGATIVE( cYesNo )
|
||||
* ACCEPT "Sure: " TO cYesNo
|
||||
* ENDDO
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -113,9 +113,9 @@
|
||||
* $EXAMPLES$
|
||||
* // Displays "Sure Y/N: " and waits until user enters Y
|
||||
* // Y/N is the string for NATIONMSG( 12 ) with default natmsg module.
|
||||
* DO WHILE !ISAFFIRM( cYesNo )
|
||||
* ACCEPT "Sure " + NATIONMSG( 12 ) + ": " TO cYesNo
|
||||
* END DO
|
||||
* DO WHILE ! ISAFFIRM( cYesNo )
|
||||
* ACCEPT "Sure " + NATIONMSG( 12 ) + ": " TO cYesNo
|
||||
* ENDDO
|
||||
* $STATUS$
|
||||
* C
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -152,13 +152,13 @@
|
||||
* aData := __objGetMsgList( oB, .T. )
|
||||
* aClassData := __objGetMsgList( oB, .T., HB_MSGLISTCLASS )
|
||||
* aMethod := __objGetMsgList( oB, .F. )
|
||||
* FOR i = 1 to len ( aData )
|
||||
* FOR i := 1 TO Len( aData )
|
||||
* ? "DATA name:", aData[ i ]
|
||||
* NEXT
|
||||
* FOR i = 1 to len ( aClassData )
|
||||
* FOR i := 1 TO Len( aClassData )
|
||||
* ? "CLASSDATA name:", aClassData[ i ]
|
||||
* NEXT
|
||||
* FOR i = 1 to len ( aMethod )
|
||||
* FOR i := 1 TO Len( aMethod )
|
||||
* ? "METHOD name:", aMethod[ i ]
|
||||
* NEXT
|
||||
* $STATUS$
|
||||
@@ -200,7 +200,7 @@
|
||||
* // show information about TBrowse class
|
||||
* oB := TBrowseNew( 0, 0, 24, 79 )
|
||||
* aMethod := __objGetMethodList( oB )
|
||||
* FOR i = 1 to len ( aMethod )
|
||||
* FOR i := 1 TO Len( aMethod )
|
||||
* ? "METHOD name:", aMethod[ i ]
|
||||
* NEXT
|
||||
* $STATUS$
|
||||
@@ -246,7 +246,7 @@
|
||||
* // show information about TBrowse class
|
||||
* oB := TBrowseNew( 0, 0, 24, 79 )
|
||||
* aData := __objGetValueList( oB )
|
||||
* FOR i = 1 to len ( aData )
|
||||
* FOR i := 1 TO len( aData )
|
||||
* ? "DATA name:", aData[ i, HB_OO_DATA_SYMBOL ], ;
|
||||
* " value=", aData[ i, HB_OO_DATA_VALUE ]
|
||||
* NEXT
|
||||
@@ -291,7 +291,7 @@
|
||||
* $EXAMPLES$
|
||||
* // set some TBrowse instance variable
|
||||
* oB := TBrowse():New()
|
||||
* aData := array( 4, 2 )
|
||||
* aData := Array( 4, 2 )
|
||||
* aData[ 1, HB_OO_DATA_SYMBOL ] = "nTop"
|
||||
* aData[ 1, HB_OO_DATA_VALUE ] = 1
|
||||
* aData[ 2, HB_OO_DATA_SYMBOL ] = "nLeft"
|
||||
@@ -354,16 +354,16 @@
|
||||
* ? oHappy:Smile( 3 ) // *SMILE*
|
||||
*
|
||||
* STATIC FUNCTION MySmile( nType )
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* CASE nType == 1
|
||||
* cSmile := ":)"
|
||||
* cSmile := ":)"
|
||||
* CASE nType == 2
|
||||
* cSmile := ";)"
|
||||
* cSmile := ";)"
|
||||
* CASE nType == 3
|
||||
* cSmile := "*SMILE*"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* cSmile := "*SMILE*"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -505,24 +505,24 @@
|
||||
* ? oHappy:Smile( 2 ) // *WINK*
|
||||
*
|
||||
* STATIC FUNCTION MySmile( nType )
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* CASE nType == 1
|
||||
* cSmile := ":)"
|
||||
* cSmile := ":)"
|
||||
* CASE nType == 2
|
||||
* cSmile := ";)"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* cSmile := ";)"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
*
|
||||
* STATIC FUNCTION YourSmile( nType )
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* CASE nType == 1
|
||||
* cSmile := "*SMILE*"
|
||||
* cSmile := "*SMILE*"
|
||||
* CASE nType == 2
|
||||
* cSmile := "*WINK*"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* cSmile := "*WINK*"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -621,14 +621,14 @@
|
||||
* ? __objHasMethod( oHappy, "Smile" ) // .F.
|
||||
*
|
||||
* STATIC FUNCTION MySmile( nType )
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* CASE nType == 1
|
||||
* cSmile := ":)"
|
||||
* cSmile := ":)"
|
||||
* CASE nType == 2
|
||||
* cSmile := ";)"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* cSmile := ";)"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -675,14 +675,14 @@
|
||||
* ? __objHasMethod( oHappy, "Smile" ) // .F.
|
||||
*
|
||||
* STATIC FUNCTION MySmile( nType )
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* LOCAL cSmile
|
||||
* DO CASE
|
||||
* CASE nType == 1
|
||||
* cSmile := ":)"
|
||||
* cSmile := ":)"
|
||||
* CASE nType == 2
|
||||
* cSmile := ";)"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* cSmile := ";)"
|
||||
* ENDCASE
|
||||
* RETURN cSmile
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -766,27 +766,27 @@
|
||||
* // Create three classes and check their relations
|
||||
*
|
||||
* #include "hbclass.ch"
|
||||
* FUNCTION main()
|
||||
* local oSuper, oObject, oDress
|
||||
* PROCEDURE Main()
|
||||
* LOCAL oSuper, oObject, oDress
|
||||
* oSuper := TMood():New()
|
||||
* oObject := THappy():New()
|
||||
* oDress := TShirt():New()
|
||||
* ? __objDerivedFrom( oObject, oSuper ) // .T.
|
||||
* ? __objDerivedFrom( oSuper, oObject ) // .F.
|
||||
* ? __objDerivedFrom( oObject, oDress ) // .F.
|
||||
* RETURN NIL
|
||||
* RETURN
|
||||
*
|
||||
* CLASS TMood
|
||||
* CREATE CLASS TMood
|
||||
* METHOD New() INLINE Self
|
||||
* ENDCLASS
|
||||
*
|
||||
* CLASS THappy FROM TMood
|
||||
* CREATE CLASS THappy FROM TMood
|
||||
* METHOD Smile() INLINE qout( "*smile*" )
|
||||
* ENDCLASS
|
||||
*
|
||||
* CLASS TShirt
|
||||
* DATA Color
|
||||
* DATA Size
|
||||
* CREATE CLASS TShirt
|
||||
* VAR Color
|
||||
* VAR Size
|
||||
* METHOD New() INLINE Self
|
||||
* ENDCLASS
|
||||
* $STATUS$
|
||||
|
||||
@@ -47,12 +47,12 @@
|
||||
* $RETURNS$
|
||||
* DBEVAL() always returns NIL
|
||||
* $DESCRIPTION$
|
||||
* Performs a code block operation on the current Database
|
||||
* Performs a code block operation on the current Database
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* PROCEDURE Main()
|
||||
* LOCAL nCount
|
||||
*
|
||||
* USE Test
|
||||
* USE test
|
||||
*
|
||||
* dbGoto( 4 )
|
||||
* ? RecNo()
|
||||
@@ -61,7 +61,7 @@
|
||||
* COUNT TO nCount NEXT 10
|
||||
* ? RecNo(), nCount
|
||||
*
|
||||
* RETURN NIL
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* S
|
||||
* $COMPLIANCE$
|
||||
@@ -92,16 +92,16 @@
|
||||
* This function returns the same alias name ofthe currently selected
|
||||
* work area.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* PROCEDURE Main()
|
||||
*
|
||||
* USE Test
|
||||
* USE test
|
||||
*
|
||||
* select 0
|
||||
* qOut( IF(DBF()=="","No Name",DBF()))
|
||||
* Test->(qOut(DBF())
|
||||
* qOut(Alias(1))
|
||||
* SELECT 0
|
||||
* QOut( iif( DBF() == "", "No Name", DBF() ) )
|
||||
* test->( QOut( DBF() ) )
|
||||
* QOut( Alias( 1 ) )
|
||||
*
|
||||
* RETURN NIL
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -152,14 +152,13 @@
|
||||
* tain multiple record locks during an appending operation. The
|
||||
* default for this parameter is a logical false (.F.).
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
*
|
||||
* USE Test
|
||||
* local cName="HARBOUR",nId=10
|
||||
* Test->(DbAppend())
|
||||
* Replace Test->Name wit cName,Id with nId
|
||||
* Use
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* LOCAL cName := "HARBOUR", nId := 10
|
||||
* USE test
|
||||
* test->( dbAppend() )
|
||||
* REPLACE test->Name WITH cName, test->Id WITH nId
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -190,19 +189,13 @@
|
||||
* This function clears any active filter condiction
|
||||
* for the current or selected work area.
|
||||
* $EXAMPLES$
|
||||
* Function Main()
|
||||
*
|
||||
* Use Test
|
||||
*
|
||||
* Set Filter to Left(Test->Name,2) == "An"
|
||||
*
|
||||
* Dbedit()
|
||||
*
|
||||
* Test->(DbClearFilter())
|
||||
*
|
||||
* USE
|
||||
*
|
||||
* Return Nil
|
||||
* PROCEDURE Main()
|
||||
* USE test
|
||||
* SET FILTER TO Left( test->Name, 2 ) == "An"
|
||||
* dbEdit()
|
||||
* Test->( dbClearFilter() )
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -234,21 +227,14 @@
|
||||
* indexes. In addition, it closes all format files and moves
|
||||
* the work area pointer to the first position
|
||||
* $EXAMPLES$
|
||||
* Function Main()
|
||||
*
|
||||
* Use Test New
|
||||
*
|
||||
* DbEdit()
|
||||
*
|
||||
* Use Test1 New
|
||||
*
|
||||
* DbEdit()
|
||||
*
|
||||
* DbCloseAll()
|
||||
*
|
||||
* USE
|
||||
*
|
||||
* Return Nil
|
||||
* PROCEDURE Main()
|
||||
* USE test NEW
|
||||
* dbEdit()
|
||||
* USE test1 NEW
|
||||
* dbEdit()
|
||||
* dbCloseAll()
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -277,12 +263,12 @@
|
||||
* This function will close any database open in the selected
|
||||
* or aliased work area.
|
||||
* $EXAMPLES$
|
||||
* Function Main()
|
||||
* Use Test
|
||||
* Dbedit()
|
||||
* Test->(DbCloseArea())
|
||||
* USE
|
||||
* Return Nil
|
||||
* PROCEDURE Main()
|
||||
* USE test
|
||||
* dbEdit()
|
||||
* Test->( dbCloseArea() )
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -313,22 +299,22 @@
|
||||
* buffers for that work area only. This function does not update all
|
||||
* open work areas.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* LOCAL cName:=SPACE(40)
|
||||
* LOCAL nId:=0
|
||||
* USE Test EXCLUSIVE NEW
|
||||
* //
|
||||
* @ 10, 10 GET cName
|
||||
* @ 11, 10 GET nId
|
||||
* READ
|
||||
* //
|
||||
* IF UPDATED()
|
||||
* APPEND BLANK
|
||||
* REPLACE Tests->Name WITH cName
|
||||
* REPLACE Tests->Id WITH nId
|
||||
* Tests->( DBCOMMIT() )
|
||||
* ENDIF
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* LOCAL cName := SPACE( 40 )
|
||||
* LOCAL nId := 0
|
||||
* USE test EXCLUSIVE NEW
|
||||
* //
|
||||
* @ 10, 10 GET cName
|
||||
* @ 11, 10 GET nId
|
||||
* READ
|
||||
* //
|
||||
* IF UPDATED()
|
||||
* APPEND BLANK
|
||||
* REPLACE tests->Name WITH cName
|
||||
* REPLACE tests->Id WITH nId
|
||||
* tests->( DBCOMMIT() )
|
||||
* ENDIF
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -358,27 +344,27 @@
|
||||
* Before the disk write is performed,all buffers are flushed.
|
||||
* open work areas.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* LOCAL cName:=SPACE(40)
|
||||
* LOCAL nId:=0
|
||||
* USE Test EXCLUSIVE NEW
|
||||
* USE TestId New INDEX Testid
|
||||
* //
|
||||
* @ 10, 10 GET cName
|
||||
* @ 11, 10 GET nId
|
||||
* READ
|
||||
* //
|
||||
* IF UPDATED()
|
||||
* APPEND BLANK
|
||||
* REPLACE Tests->Name WITH cName
|
||||
* REPLACE Tests->Id WITH nId
|
||||
* IF !TestId->(DBSEEK(nId))
|
||||
* PROCEDURE Main()
|
||||
* LOCAL cName := SPACE( 40 )
|
||||
* LOCAL nId := 0
|
||||
* USE test EXCLUSIVE NEW
|
||||
* USE testid NEW INDEX testid
|
||||
* //
|
||||
* @ 10, 10 GET cName
|
||||
* @ 11, 10 GET nId
|
||||
* READ
|
||||
* //
|
||||
* IF UPDATED()
|
||||
* APPEND BLANK
|
||||
* REPLACE Tests->Id WITH nId
|
||||
* REPLACE tests->Name WITH cName
|
||||
* REPLACE tests->Id WITH nId
|
||||
* IF ! testid->( DBSEEK( nId ) )
|
||||
* APPEND BLANK
|
||||
* REPLACE tests->Id WITH nId
|
||||
* ENDIF
|
||||
* ENDIF
|
||||
* ENDIF
|
||||
* DBCOMMITALL()
|
||||
* RETURN NIL
|
||||
* DBCOMMITALL()
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -458,21 +444,20 @@
|
||||
* The <cAlias> parameter specifies the alias name for the new opened
|
||||
* database.
|
||||
* $EXAMPLES$
|
||||
* function main()
|
||||
* PROCEDURE Main()
|
||||
* LOCAL nI, aStruct := { { "CHARACTER", "C", 25, 0 }, ;
|
||||
* { "NUMERIC", "N", 8, 0 }, ;
|
||||
* { "DOUBLE", "N", 8, 2 }, ;
|
||||
* { "DATE", "D", 8, 0 }, ;
|
||||
* { "LOGICAL", "L", 1, 0 }, ;
|
||||
* { "MEMO1", "M", 10, 0 }, ;
|
||||
* { "MEMO2", "M", 10, 0 } }
|
||||
*
|
||||
* local nI, aStruct := { { "CHARACTER", "C", 25, 0 }, ;
|
||||
* { "NUMERIC", "N", 8, 0 }, ;
|
||||
* { "DOUBLE", "N", 8, 2 }, ;
|
||||
* { "DATE", "D", 8, 0 }, ;
|
||||
* { "LOGICAL", "L", 1, 0 }, ;
|
||||
* { "MEMO1", "M", 10, 0 }, ;
|
||||
* { "MEMO2", "M", 10, 0 } }
|
||||
* REQUEST DBFCDX
|
||||
*
|
||||
* REQUEST DBFCDX
|
||||
* dbCreate( "testdbf", aStruct, "DBFCDX", .T., "MYALIAS" )
|
||||
*
|
||||
* dbCreate( "testdbf", aStruct, "DBFCDX", .t., "MYALIAS" )
|
||||
*
|
||||
* RETURN NIL
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -507,10 +492,10 @@
|
||||
* In a networking situation, this function requires that the record
|
||||
* be locked prior to issuing the DBDELETE() function.
|
||||
* $EXAMPLES$
|
||||
* nId:=10
|
||||
* USE TestId INDEX TestId NEW
|
||||
* IF TestId->(DBSEEK(nId))
|
||||
* IF TestId->(RLOCK())
|
||||
* nId := 10
|
||||
* USE testid INDEX testid NEW
|
||||
* IF testid->( DBSEEK( nId ) )
|
||||
* IF testid->( RLOCK() )
|
||||
* DBDELETE()
|
||||
* ENDIF
|
||||
* ENDIF
|
||||
@@ -546,14 +531,14 @@
|
||||
* for the current or designated work area. If no filter condition
|
||||
* is present, a NULL string will be returned.
|
||||
* $EXAMPLES$
|
||||
* USE Test INDEX Test NEW
|
||||
* SET FILTER TO Name= "Harbour"
|
||||
* USE TestId INDEX TestId NEW
|
||||
* SET FILTER TO Id = 1
|
||||
* USE test INDEX test NEW
|
||||
* SET FILTER TO Name == "Harbour"
|
||||
* USE testid INDEX testid NEW
|
||||
* SET FILTER TO Id == 1
|
||||
* SELECT Test
|
||||
* //
|
||||
* ? DBFILTER()
|
||||
* ? TestId->(DBFILTER())
|
||||
* ? testid->( DBFILTER() )
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -585,7 +570,7 @@
|
||||
* condition. Otherwise, if no index is active or if no filter condition
|
||||
* is present, the value of the record pointer will be LASTREC().
|
||||
* $EXAMPLES$
|
||||
* USE Tests
|
||||
* USE tests
|
||||
* DBGOTOP()
|
||||
* ? RECNO()
|
||||
* DBGOBOTTOM()
|
||||
@@ -634,12 +619,12 @@
|
||||
* The following example uses DBGOTO() to iteratively process
|
||||
* every fourth record:
|
||||
*
|
||||
* DBUSEAREA( .T., "DBFNTX", "Sales", "Sales", .T. )
|
||||
* DBUSEAREA( .T., "DBFNTX", "sales", "sales", .T. )
|
||||
* //
|
||||
* // toggle every fourth record
|
||||
* DO WHILE !EOF()
|
||||
* DO WHILE ! EOF()
|
||||
* DBGOTO( RECNO() + 4 )
|
||||
* Sales->Group := "Bear"
|
||||
* sales->Group := "Bear"
|
||||
* ENDDO
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -672,7 +657,7 @@
|
||||
* condition. Otherwise, if no index is active or if no filter condition
|
||||
* is present, the value of RECNO() will be 1.
|
||||
* $EXAMPLES$
|
||||
* USE Tests
|
||||
* USE tests
|
||||
* DBGOTOP()
|
||||
* ? RECNO()
|
||||
* DBGOBOTTOM()
|
||||
@@ -711,8 +696,8 @@
|
||||
* DELETE setting ON has been skipped, it no longer can be brought back
|
||||
* with DBRECALL().
|
||||
* $EXAMPLES$
|
||||
* USE Test NEW
|
||||
* DBGOTO(10)
|
||||
* USE test NEW
|
||||
* DBGOTO( 10 )
|
||||
* DBDELETE()
|
||||
* ? DELETED()
|
||||
* DBRECALL()
|
||||
@@ -754,15 +739,15 @@
|
||||
* passed it will be assumed to lock the current active record/data
|
||||
* item.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* LOCAL x:=0
|
||||
* USE Tests New
|
||||
* FOR x:=1 to reccount()
|
||||
* IF !DBRLOCK()
|
||||
* DBUNLOCK()
|
||||
* ENDIF
|
||||
* NEXT
|
||||
* USE
|
||||
* PROCEDURE Main()
|
||||
* LOCAL x := 0
|
||||
* USE tests NEW
|
||||
* FOR x := 1 TO reccount()
|
||||
* IF ! DBRLOCK()
|
||||
* DBUNLOCK()
|
||||
* ENDIF
|
||||
* NEXT
|
||||
* USE
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -795,20 +780,20 @@
|
||||
* (meaning no elements in it), then there are no locked records in that
|
||||
* work area.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* LOCAL aList:={}
|
||||
* LOCAL x:=0
|
||||
* USE Tests NEW
|
||||
* DBGOTO(10)
|
||||
* RLOCK()
|
||||
* DBGOTO(100)
|
||||
* RLOCK()
|
||||
* aList:=DBRLOCKLIST()
|
||||
* FOR x:=1 TO LEN(aList)
|
||||
* ? aList[x]
|
||||
* NEXT
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* LOCAL aList := {}
|
||||
* LOCAL x := 0
|
||||
* USE tests NEW
|
||||
* DBGOTO( 10 )
|
||||
* RLOCK()
|
||||
* DBGOTO( 100 )
|
||||
* RLOCK()
|
||||
* aList := DBRLOCKLIST()
|
||||
* FOR x := 1 TO Len( aList )
|
||||
* ? aList[ x ]
|
||||
* NEXT
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -841,15 +826,15 @@
|
||||
* specified, them the current active record/data item will be
|
||||
* unlocked
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Tests New
|
||||
* DBGOTO(10)
|
||||
* IF RLOCK()
|
||||
* ? Tests->ID
|
||||
* DBRUNLOCK()
|
||||
* ENDIF
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE tests NEW
|
||||
* DBGOTO( 10 )
|
||||
* IF RLOCK()
|
||||
* ? tests->ID
|
||||
* DBRUNLOCK()
|
||||
* ENDIF
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -905,25 +890,25 @@
|
||||
* status of SOFTSEEK before performing the operation. The default of
|
||||
* <lSoftSeek> is a logical false (.F.)
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Tests New INDEX Tests
|
||||
* DBGOTO(10)
|
||||
* nId:=Tests->nId
|
||||
* IF Tests->(DBSEEK(nId))
|
||||
* IF RLOCK()
|
||||
* ? Tests->Name
|
||||
* DBRUNLOCK()
|
||||
* ENDIF
|
||||
* ENDIF
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE tests NEW INDEX tests
|
||||
* DBGOTO( 10 )
|
||||
* nId := tests->nId
|
||||
* IF tests->( DBSEEK( nId ) )
|
||||
* IF RLOCK()
|
||||
* ? tests->Name
|
||||
* DBRUNLOCK()
|
||||
* ENDIF
|
||||
* ENDIF
|
||||
* USE
|
||||
* RETURN
|
||||
*
|
||||
* ACCEPT "Employee name: " TO cName
|
||||
* IF ( Employee->(DBSEEK(cName)) )
|
||||
* Employee->(ViewRecord())
|
||||
* IF Employee->( DBSEEK( cName ) )
|
||||
* Employee->( ViewRecord() )
|
||||
* ELSE
|
||||
* ? "Not found"
|
||||
* END
|
||||
* ENDIF
|
||||
* $STATUS$
|
||||
* S
|
||||
* $COMPLIANCE$
|
||||
@@ -961,18 +946,18 @@
|
||||
* and record pointer, as well as its own FOUND(), DBFILTER(),
|
||||
* DBRSELECT() and DBRELATION() function values.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* LOCAL nId
|
||||
* USE Tests NEW INDEX Tests
|
||||
* USE Tests1 NEW INDEX Tests1
|
||||
* DBSELECTAREA(1)
|
||||
* nId:=Tests->Id
|
||||
* DBSELECTAREA(2)
|
||||
* IF DBSEEK(nId)
|
||||
* ? Tests1->cName
|
||||
* ENDIF
|
||||
* DBCLOSEALL()
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* LOCAL nId
|
||||
* USE tests NEW INDEX tests
|
||||
* USE tests1 NEW INDEX tests1
|
||||
* DBSELECTAREA( 1 )
|
||||
* nId := tests->Id
|
||||
* DBSELECTAREA( 2 )
|
||||
* IF DBSEEK( nId )
|
||||
* ? tests1->cName
|
||||
* ENDIF
|
||||
* DBCLOSEALL()
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -1042,15 +1027,15 @@
|
||||
* make any changes made to the record visible without moving the record
|
||||
* pointer in either direction.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Tests NEW
|
||||
* DBGOTOP()
|
||||
* WHILE !EOF()
|
||||
* ? Tests->Id, Tests->Name
|
||||
* DBSKIP()
|
||||
* ENDDO
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE tests NEW
|
||||
* DBGOTOP()
|
||||
* DO WHILE ! EOF()
|
||||
* ? tests->Id, tests->Name
|
||||
* DBSKIP()
|
||||
* ENDDO
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -1087,10 +1072,10 @@
|
||||
* function will return an empty string showing no filter in that work
|
||||
* area which in fact,would be not correct.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Tests NEW
|
||||
* DBSETFILTER( {|| Tests->Id <100 }, "Tests->Id <100" )
|
||||
* DBGOTOP()
|
||||
* PROCEDURE Main()
|
||||
* USE tests NEW
|
||||
* DBSETFILTER( {|| tests->Id <100 }, "tests->Id <100" )
|
||||
* DBGOTOP()
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -1125,15 +1110,16 @@
|
||||
* LEN(DBSTRUCT()) is equal to the value obtained from FCOUNT().
|
||||
* Each subscript position
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* LOCAL aStru,x
|
||||
* USE Tests NEW
|
||||
* aStru:=DBSTRUCT()
|
||||
* FOR x:=1 TO LEN(aStru)
|
||||
* ? aStru[x,1]
|
||||
* NEXT
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* #include "dbstruct.ch"
|
||||
* PROCEDURE Main()
|
||||
* LOCAL aStru, x
|
||||
* USE tests NEW
|
||||
* aStru := dbStruct()
|
||||
* FOR x := 1 TO LEN( aStru )
|
||||
* ? aStru[ x ][ DBS_NAME ]
|
||||
* NEXT
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -1165,9 +1151,9 @@
|
||||
* in a related databases.
|
||||
* $EXAMPLES$
|
||||
* nId := 10
|
||||
* USE TestId INDEX TestId NEW
|
||||
* IF TestId->(DBSEEK(nId))
|
||||
* IF TestId->(RLOCK())
|
||||
* USE testid INDEX testid NEW
|
||||
* IF testid->( DBSEEK( nId ) )
|
||||
* IF testid->( RLOCK() )
|
||||
* DBDELETE()
|
||||
* ELSE
|
||||
* DBUNLOCK()
|
||||
@@ -1201,11 +1187,11 @@
|
||||
* $DESCRIPTION$
|
||||
* This function will remove all file and record locks in all work area.
|
||||
* $EXAMPLES$
|
||||
* nId:=10
|
||||
* USE Tests INDEX TestId NEW
|
||||
* USE Tests1 INDEX Tests NEW
|
||||
* IF TestId->(DBSEEK(nId))
|
||||
* IF TestId->(RLOCK())
|
||||
* nId := 10
|
||||
* USE tests INDEX testid NEW
|
||||
* USE tests1 INDEX tests NEW
|
||||
* IF testid->( DBSEEK( nId ) )
|
||||
* IF testid->( RLOCK() )
|
||||
* DBDELETE()
|
||||
* ELSE
|
||||
* DBUNLOCK()
|
||||
@@ -1275,7 +1261,7 @@
|
||||
* If it is not specified, the file will he opened in normal read-write
|
||||
* mode.
|
||||
* $EXAMPLES$
|
||||
* DBUSEAREA(.T.,,"Tests")
|
||||
* DBUSEAREA( .T.,, "tests" )
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
* usually FCOUNT(), before calling this function.
|
||||
*
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* PROCEDURE Main()
|
||||
* LOCAL aNames, aTypes, aLens, aDecs, nCount, nFields, i
|
||||
* USE Test
|
||||
*
|
||||
@@ -66,9 +66,9 @@
|
||||
* ? "Number of fields:", nCount
|
||||
* PrintFields( nCount ) // Information for all fields
|
||||
* PrintFields( 4 ) // Information for first 4 fields
|
||||
* RETURN NIL
|
||||
* RETURN
|
||||
*
|
||||
* FUNCTION PrintFields( nCount )
|
||||
* PROCEDURE PrintFields( nCount )
|
||||
* LOCAL aNames, aTypes, aLens, aDecs, nFields, i
|
||||
*
|
||||
* aNames := Array( nCount )
|
||||
@@ -79,11 +79,11 @@
|
||||
*
|
||||
* ? "Number of items :", nFields
|
||||
* FOR i := 1 TO nFields
|
||||
* ? i, PadR( aNames[ i ], 12 ), aTypes[ i ]
|
||||
* ?? aLens[ i ], aDecs[ i ]
|
||||
* ? i, PadR( aNames[ i ], 12 ), aTypes[ i ]
|
||||
* ?? aLens[ i ], aDecs[ i ]
|
||||
* NEXT
|
||||
* ?
|
||||
* RETURN NIL
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -117,15 +117,15 @@
|
||||
* If <nWorkArea> is not provided, the alias of the current work area is
|
||||
* returned.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* PROCEDURE Main()
|
||||
*
|
||||
* USE Test
|
||||
* select 0
|
||||
* qOut( IF(Alias()=="","No Name",Alias()))
|
||||
* Test->(qOut(Alias())
|
||||
* qOut(Alias(1))
|
||||
* USE Test
|
||||
* SELECT 0
|
||||
* QOut( iif( Alias() == "", "No Name", Alias() ) )
|
||||
* Test->( QOut( Alias() ) )
|
||||
* QOut( Alias( 1 ) )
|
||||
*
|
||||
* RETURN NIL
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -159,14 +159,14 @@
|
||||
* By default, BOF() will apply to the currently selected database unless
|
||||
* the function is preceded by an alias
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Tests NEW
|
||||
* DBGOTOP()
|
||||
* ? "Is Eof()",EOF()
|
||||
* DBGOBOTTOM()
|
||||
* ? "Is Eof()",EOF()
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE tests NEW
|
||||
* DBGOTOP()
|
||||
* ? "Is Eof()", EOF()
|
||||
* DBGOBOTTOM()
|
||||
* ? "Is Eof()", EOF()
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -201,7 +201,7 @@
|
||||
* In a network enviroment, any file that is about to be ZAPped must
|
||||
* be used exclusively.
|
||||
* $EXAMPLES$
|
||||
* USE Tests NEW index Tests
|
||||
* USE tests NEW INDEX tests
|
||||
* ZAP
|
||||
* USE
|
||||
* $STATUS$
|
||||
@@ -235,14 +235,14 @@
|
||||
* selected or designated work area ha ben marked for deletion. If not, the
|
||||
* function will return a logical false (.F.).
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Test New
|
||||
* DBGOTO()
|
||||
* DBDELETE()
|
||||
* ? "Is Record Deleted",Test->(DELETED())
|
||||
* DBRECALL()
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE test NEW
|
||||
* DBGOTO()
|
||||
* DBDELETE()
|
||||
* ? "Is Record Deleted", Test->( DELETED() )
|
||||
* DBRECALL()
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -276,14 +276,14 @@
|
||||
* If it has, the function will return a logical true (.T.); otherwise
|
||||
* a logical false (.F.) will be returnd
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Tests NEW
|
||||
* DBGOTOP()
|
||||
* ? "Is Eof()",EOF()
|
||||
* DBGOBOTTOM()
|
||||
* ? "Is Eof()",EOF()
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE tests NEW
|
||||
* DBGOTOP()
|
||||
* ? "Is Eof()", EOF()
|
||||
* DBGOBOTTOM()
|
||||
* ? "Is Eof()", EOF()
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -315,11 +315,11 @@
|
||||
* work area. If no database is open in this work area, the function will
|
||||
* return 0.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Tests NEW
|
||||
* ? "This database have ",Tests->(FCOUNT()),"Fields"
|
||||
* USE
|
||||
* RETURN Nil
|
||||
* PROCEDURE Main()
|
||||
* USE tests NEW
|
||||
* ? "This database have", tests->( FCOUNT() ), "Fields"
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -354,11 +354,11 @@
|
||||
* correspond to n avaliable field position in this work area, the function
|
||||
* will return a NIL data type.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Test NEW
|
||||
* ? Test->(FieldGet(1))
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE test NEW
|
||||
* ? test->( FieldGet( 1 ) )
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -393,14 +393,14 @@
|
||||
* existing field in the designated or selected work area, this function
|
||||
* will return a NULL byte.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* LOCAL x
|
||||
* USE Tests NEW
|
||||
* FOR x := 1 to Tests->(FCOUNT())
|
||||
* ? "Field Name",FieldName(x)
|
||||
* NEXT
|
||||
* USE
|
||||
* RETURN Nil
|
||||
* PROCEDURE Main()
|
||||
* LOCAL x
|
||||
* USE tests NEW
|
||||
* FOR x := 1 TO tests->( FCOUNT() )
|
||||
* ? "Field Name", FieldName( x )
|
||||
* NEXT
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -435,11 +435,11 @@
|
||||
* of <cField> or of no database is open in the selected work area, the func-
|
||||
* tion will return a 0.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION Main()
|
||||
* USE Test NEW
|
||||
* ? Test->(FIELDPOS("ID"))
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE test NEW
|
||||
* ? test->( FIELDPOS( "ID" ) )
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -477,8 +477,8 @@
|
||||
* assigned to the specified field. If the operation is not successful,
|
||||
* the function will return a NIL data type
|
||||
* $EXAMPLES$
|
||||
* USE Tests New
|
||||
* FIELDPUT(1,"Mr. Jones")
|
||||
* USE tests NEW
|
||||
* FIELDPUT( 1, "Mr. Jones" )
|
||||
* USE
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -513,9 +513,9 @@
|
||||
* database. This function will also unlock all records locks placed
|
||||
* by the same network station.
|
||||
* $EXAMPLES$
|
||||
* USE Tests New
|
||||
* USE tests New
|
||||
* IF FLOCK()
|
||||
* SUM Tests->Ammount
|
||||
* SUM tests->Ammount
|
||||
* ENDIF
|
||||
* USE
|
||||
* $STATUS$
|
||||
@@ -552,11 +552,11 @@
|
||||
* flag, so that a FOUND() condition may be tested in unselected work
|
||||
* areas by using an alias.
|
||||
* $EXAMPLES$
|
||||
* nId:=100
|
||||
* USE Tests NEW INDEX Tests
|
||||
* nId := 100
|
||||
* USE tests NEW INDEX tests
|
||||
* SEEK nId
|
||||
* IF FOUND()
|
||||
* ? Tests->Name
|
||||
* ? tests->Name
|
||||
* ENDIF
|
||||
* USE
|
||||
* $STATUS$
|
||||
@@ -593,7 +593,7 @@
|
||||
* functions, this functions is capable of implementing a backup and
|
||||
* restore routine.
|
||||
* $EXAMPLES$
|
||||
* USE Tests New
|
||||
* USE tests NEW
|
||||
* ? Header()
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -628,7 +628,7 @@
|
||||
* in use in the selected or designated work area, this function will
|
||||
* return a 0 value as well.
|
||||
* $EXAMPLES$
|
||||
* USE Tests NEW
|
||||
* USE tests NEW
|
||||
* ? LASTREC(), RECCOUNT()
|
||||
* $TESTS$
|
||||
*
|
||||
@@ -667,12 +667,11 @@
|
||||
* or designated database was last written to disk. This function will
|
||||
* only work for those database files in USE.
|
||||
* $EXAMPLES$
|
||||
* Function Main
|
||||
*
|
||||
* Use Tests New
|
||||
* ? Lupdate() // 04/25/2000
|
||||
* Use
|
||||
* Return Nil
|
||||
* PROCEDURE Main()
|
||||
* USE tests NEW
|
||||
* ? LUpdate()
|
||||
* USE
|
||||
* RETURN
|
||||
* $TESTS$
|
||||
*
|
||||
* $STATUS$
|
||||
@@ -718,13 +717,13 @@
|
||||
* This allow the run-time error-handling system to control the way
|
||||
* certains errors are handled.
|
||||
* $EXAMPLES$
|
||||
* USE TEST NEW Index Test
|
||||
* If !NetErr()
|
||||
* Seek Test->Name="HARBOUR"
|
||||
* If Found()
|
||||
* ? Test->Name
|
||||
* Endif
|
||||
* Endif
|
||||
* USE test NEW INDEX test
|
||||
* IF ! NetErr()
|
||||
* SEEK test->Name := "HARBOUR"
|
||||
* IF Found()
|
||||
* ? test->Name
|
||||
* ENDIF
|
||||
* ENDIF
|
||||
* USE
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -761,10 +760,10 @@
|
||||
* in use in the selected or designated work area, this function will
|
||||
* return a 0 value as well.
|
||||
* $EXAMPLES$
|
||||
* Use Test NEW
|
||||
* USE Harbour NEW
|
||||
* ? Reccount()
|
||||
* ? Test->(RECCOUNT())
|
||||
* USE test NEW
|
||||
* USE harbour NEW
|
||||
* ? RecCount()
|
||||
* ? Test->( RecCount() )
|
||||
* CLOSE ALL
|
||||
* $TESTS$
|
||||
*
|
||||
@@ -803,10 +802,10 @@
|
||||
* If the database file is empty and if the RDD is the traditional .dbf
|
||||
* file, the value of this function will be 1.
|
||||
* $EXAMPLES$
|
||||
* USE Tests NEW
|
||||
* USE tests NEW
|
||||
* DBGOTOP()
|
||||
* RECNO() // Returns 1
|
||||
* DBGOTO(50)
|
||||
* DBGOTO( 50 )
|
||||
* RECNO() // Returns 50
|
||||
* $TESTS$
|
||||
*
|
||||
@@ -844,10 +843,10 @@
|
||||
* is in use in this work area, the return value from this function
|
||||
* will be 0.
|
||||
* $EXAMPLES$
|
||||
* USE Tests NEW
|
||||
* USE tests NEW
|
||||
* DBGOTOP()
|
||||
* RECSIZE() // Returns 1
|
||||
* DBGOTO(50)
|
||||
* DBGOTO( 50 )
|
||||
* RECSIZE()
|
||||
* $TESTS$
|
||||
*
|
||||
@@ -898,10 +897,10 @@
|
||||
*
|
||||
* REPLACE (single record)
|
||||
* $EXAMPLES$
|
||||
* nId:=10
|
||||
* USE TestId INDEX TestId NEW
|
||||
* IF TestId->(DBSEEK(nId))
|
||||
* IF TestId->(RLOCK())
|
||||
* nId := 10
|
||||
* USE testid INDEX testid NEW
|
||||
* IF testid->( DBSEEK( nId ) )
|
||||
* IF testid->( RLOCK() )
|
||||
* DBDELETE()
|
||||
* ENDIF
|
||||
* ENDIF
|
||||
@@ -941,10 +940,10 @@
|
||||
* name <cAlias>. If no parameter is specified, the current work area will
|
||||
* be the return value of the function.
|
||||
* $EXAMPLES$
|
||||
* USE TESTS NEW
|
||||
* USE NAMES NEW
|
||||
* cOldArea:=SELECT("NAMES")
|
||||
* select TEST
|
||||
* USE tests NEW
|
||||
* USE names NEW
|
||||
* cOldArea := Select( "names" )
|
||||
* SELECT test
|
||||
* LIST
|
||||
* SELECT cOldArea
|
||||
* $TESTS$
|
||||
@@ -983,13 +982,13 @@
|
||||
* along with this function , it will default to the currently selected
|
||||
* work area.
|
||||
* $EXAMPLES$
|
||||
* Use TESTS NEW
|
||||
* USE Names New
|
||||
* USE tests NEW
|
||||
* USE names NEW
|
||||
* ? USED() // .T.
|
||||
* ? TESTS->(USED()) //.T.
|
||||
* ? TESTS->( USED() ) //.T.
|
||||
* CLOSE
|
||||
* ? USED() // .F.
|
||||
* Select TESTS
|
||||
* SELECT tests
|
||||
* ? USED() //.T.
|
||||
* $TESTS$
|
||||
*
|
||||
@@ -1028,8 +1027,8 @@
|
||||
* has completed its operation. On completion, the record pointer is placed
|
||||
* on the first record in the database.
|
||||
* $EXAMPLES$
|
||||
* USE Tests NEW index Tests
|
||||
* DBGOTO(10)
|
||||
* USE tests NEW INDEX tests
|
||||
* DBGOTO( 10 )
|
||||
* DELETE NEXT 10
|
||||
* PACK
|
||||
* USE
|
||||
|
||||
@@ -39,10 +39,10 @@
|
||||
*
|
||||
* This function replaces the Indexord() function.
|
||||
* $EXAMPLES$
|
||||
* USE Tests NEW VIA "DBFNTX"
|
||||
* USE tests NEW VIA "DBFNTX"
|
||||
* ? ORDBAGEXT() // Returns .ntx
|
||||
* DBCLOSEAREA()
|
||||
* USE Tests NEW VIA "DBFCDX"
|
||||
* USE tests NEW VIA "DBFCDX"
|
||||
* ? ORDBAGEXT() // Returns .cdx
|
||||
* DBCLOSEAREA()
|
||||
* $STATUS$
|
||||
@@ -86,13 +86,13 @@
|
||||
* index name or index order number. If <cOrderName> is not specified
|
||||
* or <nOrder> is 0, the Current active order will be used.
|
||||
* $EXAMPLES$
|
||||
* USE Tests VIA "DBFCDX" NEW
|
||||
* Set index to TESTs
|
||||
* USE tests VIA "DBFCDX" NEW
|
||||
* SET INDEX TO tests
|
||||
* ORDBAGNAME( "TeName" ) // Returns: Customer
|
||||
* ORDBAGNAME( "TeLast" ) // Returns: Customer
|
||||
* ORDBAGNAME( "teZip" ) // Returns: Customer
|
||||
* Set Order to Tag TeName
|
||||
* ? OrderBagName() //Return Custumer
|
||||
* SET ORDER TO TAG TeName
|
||||
* ? OrderBagName() // Returns: Custumer
|
||||
* $TESTS$
|
||||
* See Examples
|
||||
* $STATUS$
|
||||
@@ -214,10 +214,10 @@
|
||||
* added. It is does exist, then the <cOrderBagName> replaces the former
|
||||
* name in the order list in the current or specified work area.
|
||||
* $EXAMPLES$
|
||||
* USE TESTS VIA "DBFNDX" NEW
|
||||
* USE tests VIA "DBFNDX" NEW
|
||||
* ORDCREATE( "FNAME",, "Tests->fName" )
|
||||
*
|
||||
* USE TEsts VIA "DBFCDX" NEW
|
||||
* USE tests VIA "DBFCDX" NEW
|
||||
* ORDCREATE( , "lName", "tests->lName" )
|
||||
* $TESTS$
|
||||
* See examples
|
||||
@@ -265,8 +265,8 @@
|
||||
* for those drivers with support multiple orders bags (e.q. DBFCDX
|
||||
* and RDDADS drivers).
|
||||
* $EXAMPLES$
|
||||
* USE Tests VIA "DBFCDX" NEW
|
||||
* ORDdestroy( "lName", "tests" )
|
||||
* USE tests VIA "DBFCDX" NEW
|
||||
* OrdDestroy( "lName", "tests" )
|
||||
* $TESTS$
|
||||
* See examples
|
||||
* $STATUS$
|
||||
@@ -311,12 +311,12 @@
|
||||
* numeric which represent the position in the order list of the desired
|
||||
* Order.
|
||||
* $EXAMPLES$
|
||||
* USE Tests NEW via _DBFCDX
|
||||
* INDEX ON Tests->Id ;
|
||||
* TO TESTS ;
|
||||
* FOR Tests->Id > 100
|
||||
* USE tests NEW VIA "DBFCDX"
|
||||
* INDEX ON tests->ID ;
|
||||
* TO tests ;
|
||||
* FOR tests->ID > 100
|
||||
*
|
||||
* ORDFOR( "Tests" ) // Returns: Tests->Id > 100
|
||||
* ORDFOR( "tests" ) // Returns: tests->ID > 100
|
||||
* $TESTS$
|
||||
* See examples
|
||||
* $STATUS$
|
||||
@@ -357,15 +357,15 @@
|
||||
* $DESCRIPTION$
|
||||
*
|
||||
* $EXAMPLES$
|
||||
* USE Tests NEW via _DBFCDX
|
||||
* INDEX ON Tests->fName ;
|
||||
* TO Tests ;
|
||||
* FOR Tests->fName > "CK"
|
||||
* Index on Tests->Id to TestId
|
||||
* USE tests NEW VIA "DBFCDX"
|
||||
* INDEX ON tests->fName ;
|
||||
* TO tests ;
|
||||
* FOR tests->fName > "CK"
|
||||
* INDEX ON tests->Id TO TestId
|
||||
*
|
||||
* ORDKEY( "Tests" ) // Returns: Tests->fName
|
||||
* Set order to 2
|
||||
* ORDKEY() // Returns: Tests->Id
|
||||
* ORDKEY( "tests" ) // Returns: tests->fName
|
||||
* SET ORDER TO 2
|
||||
* ORDKEY() // Returns: tests->Id
|
||||
*
|
||||
* $STATUS$
|
||||
* S
|
||||
@@ -405,9 +405,9 @@
|
||||
* ".ntx". This is controled by the particular database driver that is
|
||||
* linked with the application.
|
||||
* $EXAMPLES$
|
||||
* IF INDEXEXT()==".ntx"
|
||||
* ? "Current driver being used is DBFNTX"
|
||||
* Endif
|
||||
* IF INDEXEXT() == ".ntx"
|
||||
* ? "Current driver being used is DBFNTX"
|
||||
* ENDIF
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -448,8 +448,8 @@
|
||||
* corresnponding index key at the specified order position, a NULL
|
||||
* byte will be returned.
|
||||
* $EXAMPLES$
|
||||
* USE TESTS NEW INDEX TEST1
|
||||
* ? INDEXKEY(1)
|
||||
* USE tests NEW INDEX test1
|
||||
* ? INDEXKEY( 1 )
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -486,10 +486,10 @@
|
||||
* A returned value of 0 indicated that no active index is controlling
|
||||
* the database,which therefore is in the natural order.
|
||||
* $EXAMPLES$
|
||||
* USE TESTS NEW INDEX TEST1
|
||||
* IF INDEXORD()>0
|
||||
* ? "Current order is ",INDEXORD()
|
||||
* Endif
|
||||
* USE tests NEW INDEX test1
|
||||
* IF INDEXORD() > 0
|
||||
* ? "Current order is", INDEXORD()
|
||||
* ENDIF
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -129,16 +129,16 @@
|
||||
* be included in the PICTURE string if there are both functions and
|
||||
* templates.
|
||||
* $EXAMPLES$
|
||||
* Function Main()
|
||||
* Local cVar:=Space(50)
|
||||
* Local nId:=0
|
||||
* cls
|
||||
* @ 3,1 SAY "Name" GET cVar PICTURE "@!S 30"
|
||||
* @ 4,1 SAY "Id" GET nId PICTURE "999.999"
|
||||
* READ
|
||||
* ? "The name you entered is",cVar
|
||||
* ? "The id you entered is",nId
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* LOCAL cVar := Space( 50 )
|
||||
* LOCAL nId := 0
|
||||
* CLS
|
||||
* @ 3,1 SAY "Name" GET cVar PICTURE "@!S 30"
|
||||
* @ 4,1 SAY "Id" GET nId PICTURE "999.999"
|
||||
* READ
|
||||
* ? "The name you entered is",cVar
|
||||
* ? "The id you entered is",nId
|
||||
* RETURN
|
||||
* $TESTS$
|
||||
* See Examples
|
||||
* $STATUS$
|
||||
@@ -185,12 +185,12 @@
|
||||
* For a complete list of PICTURES templates and functions, see the
|
||||
* @...GET command.
|
||||
* $EXAMPLES$
|
||||
* Function Main
|
||||
* Cls
|
||||
* @ 2,1 SAY "Harbour"
|
||||
* @ 3,1 SAY "is" COLOR "b/r+"
|
||||
* @ 4,1 SAY "Power" PICTURE "@!"
|
||||
* Return NIL
|
||||
* PROCEDURE Main()
|
||||
* CLS
|
||||
* @ 2, 1 SAY "Harbour"
|
||||
* @ 3, 1 SAY "is" COLOR "b/r+"
|
||||
* @ 4, 1 SAY "Power" PICTURE "@!"
|
||||
* RETURN
|
||||
* $TESTS$
|
||||
* See Examples
|
||||
* $STATUS$
|
||||
|
||||
@@ -584,12 +584,12 @@
|
||||
* A group of keys may be assigned the same code block/condition block
|
||||
* by using an array of key values in place on the first parameter.
|
||||
* $EXAMPLES$
|
||||
* local bOldF10 := setKey( K_F10, {|| Yahoo() } )
|
||||
* LOCAL bOldF10 := SetKey( K_F10, {|| Yahoo() } )
|
||||
* ... // some other processing
|
||||
* SetKey( K_F10, bOldF10 )
|
||||
* ... // some other processing
|
||||
* bBlock := SetKey( K_SPACE )
|
||||
* if bBlock != NIL ...
|
||||
* IF bBlock != NIL ...
|
||||
*
|
||||
* // make F10 exit current get, but only if in a get - ignores other
|
||||
* // wait-states such as menus, achoices, etc...
|
||||
@@ -635,7 +635,7 @@
|
||||
* a key, and optionally assignes the condition-block to the
|
||||
* return-parameter
|
||||
* $EXAMPLES$
|
||||
* local bOldF10, bOldF10Cond
|
||||
* LOCAL bOldF10, bOldF10Cond
|
||||
* bOldF10 := HB_SetKeyGet( K_F10, @bOldF10Cond )
|
||||
* ... // some other processing
|
||||
* SetKey( K_F10, bOldF10, bOldF10Cond )
|
||||
@@ -678,7 +678,7 @@
|
||||
* returned from a previous call to SetKeySave() - to restore that list,
|
||||
* or the value of NIL to clear the current list.
|
||||
* $EXAMPLES$
|
||||
* local aKeys := HB_SetKeySave( NIL ) // removes all current set=keys
|
||||
* LOCAL aKeys := HB_SetKeySave( NIL ) // removes all current set=keys
|
||||
* ... // some other processing
|
||||
* HB_SetKeySave( aKeys )
|
||||
* $TESTS$
|
||||
@@ -726,14 +726,14 @@
|
||||
* ACCEPT, INPUT, READ, and WAIT
|
||||
* $EXAMPLES$
|
||||
* // within ReadModal()
|
||||
* if HB_SetKeyCheck( K_ALT_X, GetActive() )
|
||||
* ... // some other processing
|
||||
* endif
|
||||
* IF HB_SetKeyCheck( K_ALT_X, GetActive() )
|
||||
* ... // some other processing
|
||||
* ENDIF
|
||||
* // within TBrowse handler
|
||||
* case HB_SetKeyCheck( nInkey, oTBrowse )
|
||||
* return
|
||||
* case nInKey == K_ESC
|
||||
* ... // some other processing
|
||||
* CASE HB_SetKeyCheck( nInkey, oTBrowse )
|
||||
* RETURN
|
||||
* CASE nInKey == K_ESC
|
||||
* ... // some other processing
|
||||
* $TESTS$
|
||||
* None definable
|
||||
* $STATUS$
|
||||
@@ -775,12 +775,12 @@
|
||||
* A group of keys may be assigned the same code block/condition block
|
||||
* by using an array of key values in place on the first parameter.
|
||||
* $EXAMPLES$
|
||||
* local bOldF10 := setKey( K_F10, {|| Yahoo() } )
|
||||
* LOCAL bOldF10 := setKey( K_F10, {|| Yahoo() } )
|
||||
* ... // some other processing
|
||||
* Set Key K_F10 to bOldF10)
|
||||
* SET KEY K_F10 TO bOldF10
|
||||
* ... // some other processing
|
||||
* bBlock := SetKey( K_SPACE )
|
||||
* if bBlock != NIL ...
|
||||
* IF bBlock != NIL ...
|
||||
*
|
||||
* // make F10 exit current get, but only if in a get - ignores other
|
||||
* // wait-states such as menus, achoices, etc...
|
||||
@@ -886,7 +886,7 @@
|
||||
* parameters with this command will default the operation to the
|
||||
* current logged drive and directory.
|
||||
* $EXAMPLES$
|
||||
* SET DEFAULT to C:\temp
|
||||
* SET DEFAULT TO C:\temp
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -917,7 +917,7 @@
|
||||
* value of the logical expression <lWrap> is a logical false (.F.),
|
||||
* the wrapping mode is set OFF; otherwise,it is set ON.
|
||||
* $EXAMPLES$
|
||||
* See Tests/menutest.prg
|
||||
* See tests/menutest.prg
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -960,7 +960,7 @@
|
||||
* witch suppresses all messages output.
|
||||
* The British spelling of CENTRE is also supported.
|
||||
* $EXAMPLES$
|
||||
* See Tests/menutest.prg
|
||||
* See tests/menutest.prg
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -1106,7 +1106,7 @@
|
||||
* be set off
|
||||
* $EXAMPLES$
|
||||
* SET CENTURY ON
|
||||
* ? DATE()
|
||||
* ? Date()
|
||||
* SET CENTURY OFF
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -1155,7 +1155,7 @@
|
||||
* </table>
|
||||
* $EXAMPLES$
|
||||
* SET DATE JAPAN
|
||||
* ? DATE()
|
||||
* ? Date()
|
||||
* SET DATE GERMAN
|
||||
* ? Date()
|
||||
* $TESTS$
|
||||
@@ -1235,7 +1235,7 @@
|
||||
* </table>
|
||||
* $EXAMPLES$
|
||||
* SET FIXED ON
|
||||
* ? 25141251/362
|
||||
* ? 25141251 / 362
|
||||
* SET FIXED OFF
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -1292,7 +1292,7 @@
|
||||
* $EXAMPLES$
|
||||
* SET PRINTER ON
|
||||
* SET PRINTER TO LPT1
|
||||
* ? 25141251/362
|
||||
* ? 25141251 / 362
|
||||
* SET PRINTER .F.
|
||||
* $STATUS$
|
||||
* R
|
||||
@@ -1326,10 +1326,10 @@
|
||||
* If <lConsole> is a logical true (.T.),the console will be turned
|
||||
* ON; otherwise, the console will be turned off.
|
||||
* $EXAMPLES$
|
||||
* SET console on
|
||||
* ? DATE()
|
||||
* SET console off
|
||||
* ? date()
|
||||
* SET CONSOLE ON
|
||||
* ? Date()
|
||||
* SET CONSOLE OFF
|
||||
* ? Date()
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -1362,9 +1362,9 @@
|
||||
* command must be activated.
|
||||
* $EXAMPLES$
|
||||
* SET FIXED ON
|
||||
* ? 25141251/362
|
||||
* ? 25141251 / 362
|
||||
* SET DECIMALS TO 10
|
||||
* ? 214514.214/6325
|
||||
* ? 214514.214 / 6325
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -1401,10 +1401,10 @@
|
||||
* the @...GET commands, the values for the GETs will all be ignored.
|
||||
* $EXAMPLES$
|
||||
* SET DEVICE TO SCREEN
|
||||
* ? 25141251/362
|
||||
* ? 25141251 / 362
|
||||
* SET DEVICE TO PRINTER
|
||||
* SET PRINTER TO LPT1
|
||||
* ? 214514.214/6325
|
||||
* ? 214514.214 / 6325
|
||||
* SET PRINTER OFF
|
||||
* SET DEVICE TO SCREEN
|
||||
* $STATUS$
|
||||
@@ -1440,10 +1440,10 @@
|
||||
* ON; otherwise, the bell will be turned off.
|
||||
* $EXAMPLES$
|
||||
* SET BELL ON
|
||||
* cDummy:=space(20)
|
||||
* @ 3,2 get cDummy
|
||||
* Read
|
||||
* SET bell off
|
||||
* cDummy := Space( 20 )
|
||||
* @ 3,2 GET cDummy
|
||||
* READ
|
||||
* SET BELL OFF
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -236,8 +236,8 @@
|
||||
* the second expression, the function will return 0. The third and fourth
|
||||
* parameters lets you indicate a starting and end offset to search in.
|
||||
* $EXAMPLES$
|
||||
* QOUT( "at( 'cde', 'abcdefgfedcba' ) = '" +;
|
||||
* at( 'cde', 'abcsefgfedcba' ) + "'" )
|
||||
* QOUT( "At( 'cde', 'abcdefgfedcba' ) = '" +;
|
||||
* At( 'cde', 'abcsefgfedcba' ) + "'" )
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -280,8 +280,8 @@
|
||||
* of <cString> to the left. If the function is unable to find any
|
||||
* occurence of <cSearch> in <cString>, the return value is 0.
|
||||
* $EXAMPLES$
|
||||
* QOUT( "rat( 'cde', 'abcdefgfedcba' ) = '" +;
|
||||
* rat( 'cde', 'abcsefgfedcba' ) + "'" )
|
||||
* QOUT( "RAt( 'cde', 'abcdefgfedcba' ) = '" +;
|
||||
* RAt( 'cde', 'abcsefgfedcba' ) + "'" )
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -408,9 +408,9 @@
|
||||
* characters from <nStart> to the end of the string is less than <nLen>
|
||||
* the rest are ignored.
|
||||
* $EXAMPLES$
|
||||
* ? SUBSTR( "HELLO HARBOUR" , 7, 4 ) // HARB
|
||||
* ? SUBSTR( "HELLO HARBOUR" ,-3, 3 ) // OUR
|
||||
* ? SUBSTR( "HELLO HARBOUR" , 7 ) // HARBOUR
|
||||
* ? SUBSTR( "HELLO HARBOUR" , 7, 4 ) // HARB
|
||||
* ? SUBSTR( "HELLO HARBOUR" , -3, 3 ) // OUR
|
||||
* ? SUBSTR( "HELLO HARBOUR" , 7 ) // HARBOUR
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -607,7 +607,7 @@
|
||||
* ? HB_VALTOSTR( 4 ) == " 4"
|
||||
* ? HB_VALTOSTR( 4.0 / 2 ) == " 2.00"
|
||||
* ? HB_VALTOSTR( "String" ) == "String"
|
||||
* ? HB_VALTOSTR( CTOD( "01/01/2001" ) ) == "01/01/01"
|
||||
* ? HB_VALTOSTR( STOD( "20010101" ) ) == "01/01/01"
|
||||
* ? HB_VALTOSTR( NIL ) == "NIL"
|
||||
* ? HB_VALTOSTR( .F. ) == ".F."
|
||||
* ? HB_VALTOSTR( .T. ) == ".T."
|
||||
@@ -688,7 +688,7 @@
|
||||
* $EXAMPLES$
|
||||
* ? EMPTY( "I'm not empty" ) // .F.
|
||||
* $TESTS$
|
||||
* FUNCTION Test()
|
||||
* PROCEDURE Test()
|
||||
* ? EMPTY( NIL ) // .T.
|
||||
* ? EMPTY( 0 ) // .T.
|
||||
* ? EMPTY( .F. ) // .T.
|
||||
@@ -697,7 +697,7 @@
|
||||
* ? EMPTY( .T. ) // .F.
|
||||
* ? EMPTY( "smile" ) // .F.
|
||||
* ? EMPTY( Date() ) // .F.
|
||||
* RETURN NIL
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -960,7 +960,7 @@
|
||||
* any character expression passed as <cCharacter>.
|
||||
* $EXAMPLES$
|
||||
* ? ASC( "A" )
|
||||
* ? ASC( "¹" )
|
||||
* ? ASC( "¹" )
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -1006,7 +1006,7 @@
|
||||
* truncate the string <xVal> from the leftmost side to the length of
|
||||
* <nWidth>.
|
||||
* $EXAMPLES$
|
||||
* ? PADC( "Harbour",20 )
|
||||
* ? PADC( "Harbour", 20 )
|
||||
* ? PADC( 34.5142, 20 )
|
||||
* ? PADC( Date(), 35 )
|
||||
* $TESTS$
|
||||
@@ -1320,41 +1320,41 @@
|
||||
* This function is useful to declare the length of a character memory
|
||||
* variable.
|
||||
* $EXAMPLES$
|
||||
* FUNC MAIN
|
||||
* LOCAL cBigString
|
||||
* LOCAL cFirst
|
||||
* LOCAL cString := Space(20) // Create an character memory variable
|
||||
* // with length 20
|
||||
* ? len(cString) // 20
|
||||
* cBigString:=space(100000) // create a memory variable with 100000
|
||||
* // blank spaces
|
||||
* ? len(cBigString)
|
||||
* Use Tests New
|
||||
* cFirst:= makeempty(1)
|
||||
* ? len(cFirst)
|
||||
* Return Nil
|
||||
* PROCEDURE Main()
|
||||
* LOCAL cBigString
|
||||
* LOCAL cFirst
|
||||
* LOCAL cString := Space( 20 ) // Create an character memory variable
|
||||
* // with length 20
|
||||
* ? Len( cString ) // 20
|
||||
* cBigString := space( 100000 ) // create a memory variable with 100000
|
||||
* // blank spaces
|
||||
* ? Len( cBigString )
|
||||
* USE tests NEW
|
||||
* cFirst := MakeEmpty( 1 )
|
||||
* ? Len( cFirst )
|
||||
* RETURN
|
||||
*
|
||||
* Function MakeEmpty(xField)
|
||||
* LOCAL nRecord
|
||||
* LOCAL xRetValue
|
||||
* FUNCTION MakeEmpty( xField )
|
||||
* LOCAL nRecord
|
||||
* LOCAL xRetValue
|
||||
*
|
||||
* If !empty(alias())
|
||||
* nRecord:=recno()
|
||||
* dbgoto(0)
|
||||
* if valtype(xField)=="C"
|
||||
* xField:= ascan(dbstruct(),{|aFields| aFields[1]==upper(xfield)})
|
||||
* else
|
||||
* default xField to 0
|
||||
* if xField < 1 .or. xField>fcount()
|
||||
* xfield:=0
|
||||
* endif
|
||||
* endif
|
||||
* if !(xfield ==0)
|
||||
* xRetvalue:=fieldget(xfield)
|
||||
* endif
|
||||
* dbgoto(nrecord)
|
||||
* endif
|
||||
* return xRetvalue
|
||||
* IF ! Empty( Alias() )
|
||||
* nRecord := RecNo()
|
||||
* dbgoto( 0 )
|
||||
* IF ValType( xField ) == "C"
|
||||
* xField := AScan( dbstruct(), {| aFields | aFields[ 1 ] == Upper( xfield ) } )
|
||||
* ELSE
|
||||
* DEFAULT xField TO 0
|
||||
* IF xField < 1 .OR. xField > FCount()
|
||||
* xfield := 0
|
||||
* ENDIF
|
||||
* ENDIF
|
||||
* IF !( xfield == 0 )
|
||||
* xRetvalue := FieldGet( xfield )
|
||||
* ENDIF
|
||||
* dbgoto( nrecord )
|
||||
* ENDIF
|
||||
* RETURN xRetvalue
|
||||
* $TESTS$
|
||||
* See examples
|
||||
* $STATUS$
|
||||
|
||||
@@ -248,7 +248,7 @@
|
||||
* To remove an keypress/code block definition, specify NIL for <bBlock>
|
||||
* oTb:SetKey(K_ESC,nil)
|
||||
* $EXAMPLES$
|
||||
* oTb:SeyKey(K_F10,{|otb,nkey| ShowListByname(otb)}
|
||||
* oTb:SeyKey( K_F10, {| otb, nkey | ShowListByname( otb ) }
|
||||
* $END$
|
||||
*/
|
||||
|
||||
@@ -279,12 +279,12 @@
|
||||
* This method evaluate an code block associated with <nkey> that is
|
||||
* contained in the TBrowse:setkey() dictionary.
|
||||
* $EXAMPLES$
|
||||
* while .t.
|
||||
* oTb:forceStable()
|
||||
* if (oTb:applykey(inkey(0))==-1)
|
||||
* exit
|
||||
* endif
|
||||
* enddo
|
||||
* DO WHILE .T.
|
||||
* oTb:forceStable()
|
||||
* IF oTb:applykey( Inkey( 0 ) ) == -1
|
||||
* EXIT
|
||||
* ENDIF
|
||||
* ENDDO
|
||||
* $END$
|
||||
*/
|
||||
|
||||
|
||||
@@ -47,12 +47,12 @@
|
||||
* New() Create a new instance of the class
|
||||
* $EXAMPLES$
|
||||
* FUNCTION TestObject()
|
||||
* local oObject
|
||||
* LOCAL oObject
|
||||
*
|
||||
* oObject := HBClass():New("TMyClass")
|
||||
* oObject:End()
|
||||
* oObject := HBClass():New("TMyClass")
|
||||
* oObject:End()
|
||||
*
|
||||
* RETURN Nil
|
||||
* RETURN NIL
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -267,14 +267,14 @@
|
||||
* // show message and let end user select panic level
|
||||
* nChoice := ALERT( cMessage, aOptions )
|
||||
* DO CASE
|
||||
* CASE nChoice == 0
|
||||
* // do nothing, blame it on some one else
|
||||
* CASE nChoice == 1
|
||||
* ? "Please call home and tell them you're gonn'a be late"
|
||||
* CASE nChoice == 2
|
||||
* // make sure your resume is up to date
|
||||
* CASE nChoice == 3
|
||||
* ? "Oops mode is not working in this version"
|
||||
* CASE nChoice == 0
|
||||
* // do nothing, blame it on some one else
|
||||
* CASE nChoice == 1
|
||||
* ? "Please call home and tell them you're gonn'a be late"
|
||||
* CASE nChoice == 2
|
||||
* // make sure your resume is up to date
|
||||
* CASE nChoice == 3
|
||||
* ? "Oops mode is not working in this version"
|
||||
* ENDCASE
|
||||
* $STATUS$
|
||||
* R
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
* MENU TO What_Is_Bug
|
||||
*
|
||||
* PROCEDURE ShowVar
|
||||
* ALERT( READVAR() ) // WHAT_IS_BUG in red ALERT() box
|
||||
* Alert( ReadVar() ) // WHAT_IS_BUG in red ALERT() box
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -64,11 +64,11 @@
|
||||
* command. The path may be specified, along, with (the drive letter,
|
||||
* in <cLabelName>
|
||||
* $EXAMPLES$
|
||||
* FUNCTION MAIN()
|
||||
* USE Test New
|
||||
* LABEL FORM EE
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE test NEW
|
||||
* LABEL FORM EE
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -92,11 +92,11 @@
|
||||
* If the NOCONSOLE clause is specified,output to the console will be
|
||||
* turned off while this command is being executed.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION() MAIN
|
||||
* USE Test New
|
||||
* Report FORM EE
|
||||
* USE
|
||||
* RETURN NIL
|
||||
* PROCEDURE Main()
|
||||
* USE test NEW
|
||||
* REPORT FORM EE
|
||||
* USE
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
|
||||
@@ -134,26 +134,26 @@
|
||||
* It releases variable even if this variable was created in different
|
||||
* procedure
|
||||
* $EXAMPLES$
|
||||
* PROCEDURE MAIN()
|
||||
* PRIVATE mPrivate
|
||||
* PROCEDURE Main()
|
||||
* PRIVATE mPrivate
|
||||
*
|
||||
* mPrivate :="PRIVATE from MAIN()"
|
||||
* ? mPrivate //PRIVATE from MAIN()
|
||||
* Test()
|
||||
* ? mPrivate //PRIVATE from MAIN()
|
||||
* mPrivate :="PRIVATE from MAIN()"
|
||||
* ? mPrivate //PRIVATE from MAIN()
|
||||
* Test()
|
||||
* ? mPrivate //PRIVATE from MAIN()
|
||||
*
|
||||
* RETURN
|
||||
* RETURN
|
||||
*
|
||||
* PROCEDURE Test()
|
||||
* PRIVATE mPrivate
|
||||
* PRIVATE mPrivate
|
||||
*
|
||||
* mPrivate :="PRIVATE from Test()"
|
||||
* ? mPrivate //PRIVATE from TEST()
|
||||
* RELEASE mPrivate
|
||||
* ? mPrivate //NIL
|
||||
* mPrivate :="Again in Test()"
|
||||
* mPrivate :="PRIVATE from Test()"
|
||||
* ? mPrivate //PRIVATE from TEST()
|
||||
* RELEASE mPrivate
|
||||
* ? mPrivate //NIL
|
||||
* mPrivate :="Again in Test()"
|
||||
*
|
||||
* RETURN
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -232,30 +232,30 @@
|
||||
* HB_MV_PRIVATE_LOCAL =for private variables declared in current
|
||||
* function/procedure
|
||||
* $EXAMPLES$
|
||||
* PROCEDURE MAIN()
|
||||
* PUBLIC mPublic
|
||||
* PRIVATE mPrivateGlobal
|
||||
* PROCEDURE Main()
|
||||
* PUBLIC mPublic
|
||||
* PRIVATE mPrivateGlobal
|
||||
*
|
||||
* CallProc()
|
||||
* ? __mvScope( "mPrivateLocal" ) //HB_MV_UNKNOWN
|
||||
* CallProc()
|
||||
* ? __mvScope( "mPrivateLocal" ) //HB_MV_UNKNOWN
|
||||
*
|
||||
* RETURN
|
||||
* RETURN
|
||||
*
|
||||
* PROCEDURE CallProc()
|
||||
* PRIVATE mPrivateLocal
|
||||
* PRIVATE mPrivateLocal
|
||||
*
|
||||
* ? __mvScope( "mPublic" ) //HB_MV_PUBLIC
|
||||
* ? __mvScope( "mPrivateGlobal" ) //HB_MV_PRIVATE_GLOBAL
|
||||
* ? __mvScope( "mPrivateLocal" ) //HB_MV_PRIVATE_LOCAL
|
||||
* ? __mvScope( "mFindMe" ) //HB_MV_NOT_FOUND
|
||||
* ? __mvScope( "mPublic" ) //HB_MV_PUBLIC
|
||||
* ? __mvScope( "mPrivateGlobal" ) //HB_MV_PRIVATE_GLOBAL
|
||||
* ? __mvScope( "mPrivateLocal" ) //HB_MV_PRIVATE_LOCAL
|
||||
* ? __mvScope( "mFindMe" ) //HB_MV_NOT_FOUND
|
||||
*
|
||||
* IF( __mvScope( "mPublic" ) > HB_MV_ERROR )
|
||||
* ? "Variable exists"
|
||||
* ELSE
|
||||
* ? "Variable not created yet"
|
||||
* ENDIF
|
||||
* IF __mvScope( "mPublic" ) > HB_MV_ERROR
|
||||
* ? "Variable exists"
|
||||
* ELSE
|
||||
* ? "Variable not created yet"
|
||||
* ENDIF
|
||||
*
|
||||
* RETURN
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -352,63 +352,63 @@
|
||||
*
|
||||
* LOCAL nCount, i, xValue, cName
|
||||
*
|
||||
* nCount =_mvDBGINFO( HB_MV_PUBLIC )
|
||||
* FOR i:=1 TO nCount
|
||||
* xValue =__mvDBGINFO( HB_MV_PUBLIC, i, @cName )
|
||||
* ? i, cName, xValue
|
||||
* nCount := _mvDBGINFO( HB_MV_PUBLIC )
|
||||
* FOR i := 1 TO nCount
|
||||
* xValue := __mvDBGINFO( HB_MV_PUBLIC, i, @cName )
|
||||
* ? i, cName, xValue
|
||||
* NEXT
|
||||
* $TESTS$
|
||||
* #include "hbmemvar.ch"
|
||||
* PROCEDURE MAIN()
|
||||
*
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
*
|
||||
* PUBLIC cPublic := "cPublic in MAIN"
|
||||
* PUBLIC cPublic := "cPublic in MAIN"
|
||||
*
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
*
|
||||
* PRIVATE cPrivate := "cPrivate in MAIN"
|
||||
* PRIVATE cPrivate := "cPrivate in MAIN"
|
||||
*
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
*
|
||||
* CountMemvars()
|
||||
* CountMemvars()
|
||||
*
|
||||
* ? "Back in Main"
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
* ? "Back in Main"
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
*
|
||||
* RETURN
|
||||
* RETURN
|
||||
*
|
||||
* PROCEDURE CountMemvars()
|
||||
* LOCAL i, nCnt, xVal, cName
|
||||
* PUBLIC ccPublic := "ccPublic"
|
||||
* PRIVATE ccPrivate := "ccPrivate"
|
||||
* LOCAL i, nCnt, xVal, cName
|
||||
* PUBLIC ccPublic := "ccPublic"
|
||||
* PRIVATE ccPrivate := "ccPrivate"
|
||||
*
|
||||
* ? "In CountMemvars"
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
* ? "In CountMemvars"
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
*
|
||||
* PRIVATE cPublic := "cPublic"
|
||||
* PRIVATE cPublic := "cPublic"
|
||||
*
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
* ? "PUBLIC=", __mvDBGINFO( HB_MV_PUBLIC )
|
||||
* ? "PRIVATE=", __mvDBGINFO( HB_MV_PRIVATE )
|
||||
*
|
||||
* nCnt =__mvDBGINFO( HB_MV_PRIVATE ) +1
|
||||
* FOR i:=1 TO nCnt
|
||||
* xVal =__mvDBGINFO( HB_MV_PRIVATE, i, @cName )
|
||||
* ? i, "=", cName, xVal
|
||||
* NEXT
|
||||
* nCnt := __mvDBGINFO( HB_MV_PRIVATE ) + 1
|
||||
* FOR i := 1 TO nCnt
|
||||
* xVal := __mvDBGINFO( HB_MV_PRIVATE, i, @cName )
|
||||
* ? i, "=", cName, xVal
|
||||
* NEXT
|
||||
*
|
||||
* nCnt =__mvDBGINFO( HB_MV_PUBLIC ) +1
|
||||
* FOR i:=1 TO nCnt
|
||||
* xVal =__mvDBGINFO( HB_MV_PUBLIC, i, @cName )
|
||||
* ? i, "=", cName, xVal
|
||||
* NEXT
|
||||
* nCnt := __mvDBGINFO( HB_MV_PUBLIC ) + 1
|
||||
* FOR i := 1 TO nCnt
|
||||
* xVal := __mvDBGINFO( HB_MV_PUBLIC, i, @cName )
|
||||
* ? i, "=", cName, xVal
|
||||
* NEXT
|
||||
*
|
||||
* RETURN
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -482,10 +482,10 @@
|
||||
* The variable is specified by its name passed as the function parameter.
|
||||
* $EXAMPLES$
|
||||
* FUNCTION MEMVARBLOCK( cMemvar )
|
||||
* RETURN {|x| ;
|
||||
* IIF( PCOUNT()==0, ;
|
||||
* __MVGET( cMemvar ),;
|
||||
* __MVPUT( cMemvar, x ) ) }
|
||||
* RETURN {| x | ;
|
||||
* iif( PCOUNT() == 0, ;
|
||||
* __MVGET( cMemvar ),;
|
||||
* __MVPUT( cMemvar, x ) ) }
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -524,10 +524,10 @@
|
||||
* If a value is not specified then the NIL is assumed
|
||||
* $EXAMPLES$
|
||||
* FUNCTION MEMVARBLOCK( cMemvar )
|
||||
* RETURN {|x| ;
|
||||
* IIF( PCOUNT()==0, ;
|
||||
* __MVGET( cMemvar ),;
|
||||
* __MVPUT( cMemvar, x ) ) }
|
||||
* RETURN {| x | ;
|
||||
* iif( PCOUNT() == 0, ;
|
||||
* __MVGET( cMemvar ),;
|
||||
* __MVPUT( cMemvar, x ) ) }
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -565,15 +565,15 @@
|
||||
* value of given variable - the passed value is also returned
|
||||
* as a value of the codeblock evaluation.
|
||||
* $EXAMPLES$
|
||||
* PROCEDURE MAIN()
|
||||
* LOCAL cbSetGet
|
||||
* PUBLIC xPublic
|
||||
* PROCEDURE Main()
|
||||
* LOCAL cbSetGet
|
||||
* PUBLIC xPublic
|
||||
*
|
||||
* cbSetGet = MEMVARBLOCK( "xPublic" )
|
||||
* EVAL( cbSetGet, "new value" )
|
||||
* ? "Value of xPublic variable", EVAL( cbSetGet )
|
||||
* cbSetGet := MEMVARBLOCK( "xPublic" )
|
||||
* EVAL( cbSetGet, "new value" )
|
||||
* ? "Value of xPublic variable", EVAL( cbSetGet )
|
||||
*
|
||||
* RETURN
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -677,11 +677,11 @@
|
||||
* // open a file named One in work area 1
|
||||
* // that have a field named "name"
|
||||
* SELECT 1
|
||||
* USE One
|
||||
* USE one
|
||||
* // open a file named Two in work area 2
|
||||
* // it also have a field named "name"
|
||||
* SELECT 2
|
||||
* USE Two
|
||||
* USE two
|
||||
* SELECT 1
|
||||
* ? "Original names: ", One->name, Two->name
|
||||
* ? "Name value for file Two :", EVAL( bField )
|
||||
@@ -757,22 +757,22 @@
|
||||
* argument with a valid Harbour expression - the data type of this
|
||||
* expression is returned.
|
||||
* $EXAMPLES$
|
||||
* ? TYPE( "{ 1, 2 }" ) //prints "A"
|
||||
* ? TYPE( "IIF(.T., SUBSTR("TYPE",2,1), .F.)" ) //prints "C"
|
||||
* ? TYPE( "AT( "OK", MyUDF())>0" ) //prints "UI"
|
||||
* ? TYPE( "{ 1, 2 }[ 5 ]" ) //prints "UE"
|
||||
* ? TYPE( "{ 1, 2 }" ) // prints "A"
|
||||
* ? TYPE( "iif( .T., SubStr( "TYPE", 2, 1 ), .F. )" ) // prints "C"
|
||||
* ? TYPE( "At( "OK", MyUDF() ) > 0" ) // prints "UI"
|
||||
* ? TYPE( "{ 1, 2 }[ 5 ]" ) // prints "UE"
|
||||
*
|
||||
* //--------------------------------------------------------
|
||||
*
|
||||
* LOCAL c
|
||||
* PRIVATE a:="A", b:="B"
|
||||
* ? TYPE( "a + b + c" ) //prints: "U" ('C' variable is a local one)
|
||||
* PRIVATE a := "A", b := "B"
|
||||
* ? TYPE( "a + b + c" ) // prints: "U" ('C' variable is a local one)
|
||||
*
|
||||
* //--------------------------------------------------------
|
||||
*
|
||||
* LOCAL cFilter := SPACE( 60 )
|
||||
* LOCAL cFilter := Space( 60 )
|
||||
* ACCEPT "Enter filter expression:" TO cFilter
|
||||
* IF( TYPE( cFilter ) $ "CDLMN" ) )
|
||||
* IF TYPE( cFilter ) $ "CDLMN"
|
||||
* // this is a valid expression
|
||||
* SET FILTER TO &cFilter
|
||||
* ENDIF
|
||||
@@ -783,7 +783,7 @@
|
||||
* In the following code:
|
||||
*
|
||||
* PRIVATE lCond := 0
|
||||
* ? TYPE( "IIF( lCond, 'true', MyUDF() )" )
|
||||
* ? TYPE( "iof( lCond, 'true', MyUDF() )" )
|
||||
*
|
||||
* CA-Cl*pper will print "UE" - in Harbour the output will be "UI"
|
||||
*
|
||||
@@ -840,7 +840,7 @@
|
||||
* $EXAMPLES$
|
||||
* See Test(s)
|
||||
* $TESTS$
|
||||
* function Test()
|
||||
* PROCEDURE Test()
|
||||
* ? ValType( Array( 1 ) ) // "A"
|
||||
* ? ValType( {|| 1 + 1 } ) // "B"
|
||||
* ? ValType( "HARBOUR" ) // "C"
|
||||
@@ -851,7 +851,7 @@
|
||||
* ? ValType( hb_idleadd() ) // "P" Harbour extension
|
||||
* ? ValType( @QOut() ) // "S" Harbour extension
|
||||
* ? ValType( NIL ) // "U"
|
||||
* return nil
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
@@ -898,19 +898,19 @@
|
||||
* $EXAMPLES$
|
||||
* See Tests
|
||||
* $TESTS$
|
||||
* function Main()
|
||||
* local cVar := "Test local"
|
||||
* private nVar := 0
|
||||
* PROCEDURE Main()
|
||||
* LOCAL cVar := "Test local"
|
||||
* PRIVATE nVar := 0
|
||||
*
|
||||
* Test( @cVar, @nVar, cVar, nVar )
|
||||
* return nil
|
||||
* RETURN
|
||||
*
|
||||
* procedure Test( Arg1, Arg2, Arg3, Arg4 )
|
||||
* PROCEDURE Test( Arg1, Arg2, Arg3, Arg4 )
|
||||
* ? hb_isbyref( @Arg1 ) // .T.
|
||||
* ? hb_isbyref( @Arg2 ) // .T.
|
||||
* ? hb_isbyref( @Arg3 ) // .F.
|
||||
* ? hb_isbyref( @Arg4 ) // .F.
|
||||
* return
|
||||
* RETURN
|
||||
* $STATUS$
|
||||
* S
|
||||
* $COMPLIANCE$
|
||||
|
||||
Reference in New Issue
Block a user