Thanks, I will have a close look!
Just an FYI - the FILE() statement caused me problems in my last application update. the file I was checking for was at the root level of a drive (not a subdirectory) and was also in the PATH. under these conditions FILE() always returns .T.
>
>FILE('c:\myfile.txt') will return .T. if mytext.txt is in the path. even if c:\myfile.txt does not exist. a work around was suggested below. since it changes the PATH to nothing, myfile.txt is guaranteed not to be in the PATH.
>
>* lcfile is the file to check for in the root
>lcpath = SET('PATH')
>SET PATH TO
>? FILE()
>SET PATH TO (lcpath)
>
>
>Brenda
"Build a man a fire, and he's warm for a day.
Set a man on fire, and he's warm for the rest of his life."