Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- MICROSYS C & Clipper Functions - <b>b_tempfile()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
b_tempfile()


Syntax:     b_tempfile(<expC1>, <expC2>, <expC3>)

Purpose:    Creates a file with unique name

Arguments:  <expC1> is the first three (3) letters of temp filename

            <expC2> is the extention

            <expC3> is the DOS directory

Returns:    A character string of the unique DOS filename

Note :      A zero byte file is created in the specified DOS directory

Library:    MICROSYS.LIB

----------------------------------- Example ----------------------------------

   if dbopen("hq_loc")
       tmp_file := b_tempfile("loi","dbf","z:\bhq\systest\tempfile")
       if( empty(tmp_file) )
           dbclosearea()
           qout("Unable to create temp file!")
           retu(.f.)
       else
           copy to (tmp_file) for state == "42"
           use (tmp_file) excl new
           ........
           ........
           ........
           dbclosearea()
           b_erase( (tmp_file) )
           sele hq_loc
           dbclosearea()
       endi
   endi

See Also: b_erase()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson