Guys, anyone have a routine for creating a truly unique file name in Clipper 5.2e. The one my clients are using on occasion creates a file name that is NOT unique.
The above will only create 9999 files.
You could also add the code below in case the file already exists:
TEMPDBF:="TEMP"+SUBS(TIME(),7,2)+SUBS(TIME(),4,2)+".DBF"
do while file(TEMPDBF)
TEMPDBF:="TEMP"+SUBS(TIME(),7,2)+SUBS(TIME(),4,2)+".DBF"
enddo Ian Boys
DTE Systems Ltd
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.