Files
harbour-core/harbour/contrib/hbmisc/tests/testhbf.prg
Viktor Szakats bfe79a7bf9 2010-02-07 12:48 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
* contrib/hbbmcdx/bmdbfcdx.c
  * contrib/hbbmcdx/hbbmcdx.h
  * contrib/hbbtree/hb_btree.h
  * contrib/hbbtree/hb_btree.c
  * contrib/hbnetio/netiocli.c
  * contrib/hbnetio/netiosrv.c
  * contrib/rddsql/sddmy/mysqldd.c
  * contrib/rddsql/sddpg/pgsqldd.c
  * contrib/rddsql/sddfb/fbirddd.c
  * contrib/rddsql/sddodbc/odbcdd.c
  * contrib/rddsql/hbrddsql.h
  * contrib/rddsql/sqlbase.c
  * contrib/rddsql/sqlmix.c
  * contrib/rddads/adsx.c
  * contrib/rddads/ads1.c
  * contrib/xhb/bkgtsks.c
  * contrib/xhb/hbcrypt.c
  * contrib/xhb/dbf2txt.c
  * contrib/xhb/xhbcopyf.c
  * contrib/xhb/xhbfunc.c
  * contrib/xpp/philesx.c
  * contrib/hbnf/ftattr.c
    * USHORT -> HB_USHORT

  * contrib/xhb/xhbsave.c
    * USHORT -> int

  * contrib/xhb/filestat.c
    * USHORT -> HB_FATTR

  * contrib/hbmemio/memio.c
    * USHORT -> HB_USHORT
    * USHORT -> HB_ERRCODE

  * contrib/hbqt/gtqtc/gtqtc.cpp
  * contrib/hbqt/gtqtc/gtqtc.h
    * USHORT -> int, HB_USHORT

  * contrib/hbnf/fttext.c
  * contrib/hbmisc/hb_f.c
    + Added "largefile" support. (at least on the low-level)
    * USHORT -> HB_USHORT

  * contrib/hbmisc/tests/testhbf.prg
    - Deleted old comment.
2010-02-08 11:50:58 +00:00

56 lines
994 B
Plaintext

//
// $Id$
//
/*
test program for hb_f*()
harbour clones for nanfor's ft_f*()
inplementation of :
* hb_fuse()
* hb_fskip()
* hb_feof()
* hb_frecno()
* hb_freadln()
* hb_flastrec()
* hb_fgoto()
* hb_fgotop()
* hb_fgobottom()
*/
function main()
// open a text file here
if hb_fuse( "testhbf.prg", 0 ) > 1
while !hb_feof()
qout( "line " + str(hb_frecno(),2) + " " + hb_freadln() )
hb_fskip(1)
end
qout("")
my_goto(18)
my_goto(2)
hb_fgobottom()
qout("")
qout( "after hb_fgobottom() now in line # " + ltrim(str(hb_frecno())) )
hb_fgotop()
qout("")
qout( "after hb_fgotop() now in line # " + ltrim(str(hb_frecno())) )
qout("")
qout( "hb_flastrec() = " + ltrim(str(hb_flastrec())) )
// close the file
hb_fuse()
end
return nil
static function my_goto( n_go )
hb_fgoto( n_go )
qout("")
qout( "after hb_fgoto("+ltrim(str(n_go))+")" )
qout( "line "+ ltrim(str(hb_frecno())) + " is " + ltrim( hb_freadln() ) )
return nil