Glenn J. Koster, Sr. wrote:
> Is there any way through FINFO to tell if a file is permanent or
> temporary? If you simply do an FINFO("<filename>","EXISTS"), it returns
> true regardless of the domain.
>
Here's an example based on part of a login shell script I wrote to stop
a user executing a temporary command file they have created:
USER DEFINED COMMAND FILE: DOCMD.PUB.HPSDMF
parm command
setvar cmdfile ups("!command")
if finfo(cmdfile,"exists") then
if finfo(cmdfile,"intfopt") band 3 = 2 then
echo Can't execute temporary command file
else
!cmdfile
endif
else
echo !cmdfile does not exist
endif