[comp.sys.mac.hypercard] Checking file existence from within Hypercard

Scot.Kamins@f555.n125.z1.FIDONET.ORG (Scot Kamins) (12/02/88)

This script will tell you what you want to know. Pass it the file name you want to check, and you're on your way:
 
on checkFile myFile
  open file myFile
  read from file myFile for 1000 -- Well into the file
  close file myFile
  if it is empty then put myFile & " is empty."
  else put myFile & " has live data!"
end checkFile
 
OK?


--  
Scot Kamins - via FidoNet node 1:125/406
UUCP: ...!sun!hoptoad!fidogate!555!Scot.Kamins
ARPA: Scot.Kamins@f555.n125.z1.FIDONET.ORG