* contrib/hbformat/hbfmtcls.prg
! fixed casing of some function names.
* utils/hbmk2/hbmk2.prg
; all changes below apply to .xhp (xMate) to .hbp conversion:
! properly convert input filenames with spaces in them
! remove lib prefix from .a input filenames
% do not add empty -L options
* do not add include paths with %HB_INSTALL%\ in them
+ split non-portable, Borland-specific include path lists
concatenated with ';' into distinct -I options
% do not add empty include paths
* tests/testop.prg
* tests/testntx.prg
* tests/vmasort.prg
* tests/testlbl.prg
* tests/testidle.prg
* tests/videotst.prg
* tests/testmem.prg
* tests/testinit.prg
* tests/testhtml.prg
* tests/tstcolor.prg
* tests/vidtest.prg
* tests/tstuse.prg
* tests/vec1.prg
* tests/while.prg
* tests/tstdspac.prg
* tests/version.prg
* tests/testpre.prg
* tests/tstprag.prg
* formatted. mostly with hbformat.
55 lines
1.4 KiB
Plaintext
55 lines
1.4 KiB
Plaintext
/*
|
|
* $Id$
|
|
*/
|
|
|
|
#define EOL Chr( 13 ) + Chr( 10 )
|
|
#command ? [<x,...>] => OutStd( EOL )[;OutStd( <x> )]
|
|
|
|
PROCEDURE Main()
|
|
|
|
? OS(), Version()
|
|
IF ! hb_FileExists( "_tst.dbf" )
|
|
dbCreate( "_tst", { { "F1","C",1,0 } } )
|
|
ENDIF
|
|
IF ! hb_FileExists( "_tst2.dbf" )
|
|
dbCreate( "_tst2", { { "F1","C",1,0 } } )
|
|
ENDIF
|
|
|
|
USE _tst NEW ALIAS "ONE" EXCLUSIVE
|
|
? Select(), Alias(), NetErr(), Used()
|
|
?
|
|
|
|
mkTest( .T. , "NORDD", , "TWO", .T. , .F. )
|
|
mkTest( .T. , "DBF", , "TWO", .T. , .F. )
|
|
mkTest( .T. , "DBF", "", "TWO", .T. , .F. )
|
|
mkTest( .T. , "DBF", "nofile", "TWO", .T. , .F. )
|
|
mkTest( .T. , "DBF", "_tst2", "ONE", .T. , .F. )
|
|
mkTest( .T. , "DBF", "_tst", "ONE", .T. , .F. )
|
|
mkTest( .T. , "DBF", "_tst", "TWO", .T. , .F. )
|
|
?
|
|
dbUseArea( .T. , "DBF", "_tst", "ONE", .T. , .F. )
|
|
? Select(), Alias(), NetErr(), Used()
|
|
dbUseArea( .T. , "DBF", "_tst", "TWO", .T. , .F. )
|
|
? Select(), Alias(), NetErr(), Used()
|
|
?
|
|
dbSelectArea( 1 )
|
|
mkTest( .F. , "NORDD", , "TWO", .T. , .F. )
|
|
?
|
|
|
|
RETURN
|
|
|
|
PROCEDURE mkTest( lNewArea, cRdd, cFile, cAlias, lShared, lReadOnly )
|
|
|
|
LOCAL cbErr := ErrorBlock( { |oErr|break( oErr ) } ), oErr
|
|
|
|
NetErr( .F. )
|
|
BEGIN SEQUENCE
|
|
dbUseArea( lNewArea, cRdd, cFile, cAlias, lShared, lReadOnly )
|
|
RECOVER USING oErr
|
|
? "Error:", oErr:subCode, oErr:description, oErr:operation, oErr:osCode
|
|
END
|
|
? Select(), Alias(), NetErr(), Used()
|
|
ErrorBlock( cbErr )
|
|
|
|
RETURN
|