something like this:

  -- create an instance of fileio
  pFileioObj = new(xtra "fileio")
  openFile(pFileioObj, pathToExternalFile, 1)
-- (for that last parameter: 0 Read/Write, 1 Read, 2 Write)

errorCode = status(pFileioObj)
  if errorCode <> 0 then
    -- error code shows file has not opened correctly
    if errorCode = -37 then
   -- file not found. do what you gotta do.
    end if


--bhakti



"stacey.i.strickler.1" wrote:
> 
> I am having trouble checking to see if a file exists using FileIO. I know
> if I try to open a file that is not there I get an error of -37, which is
> a bad file name. How would I go about getting this into a variable so I
> can check the variable to see if the file exists?
> 
> Stacey
> 
> [To remove yourself from this list, or to change to digest mode, go to 
>http://www.penworks.com/lingo-l.cgi  To post messages to the list, email 
>[EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for 
>learning and helping with programming Lingo.  Thanks!]
[To remove yourself from this list, or to change to digest mode, go to 
http://www.penworks.com/lingo-l.cgi  To post messages to the list, email 
[EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED]). Lingo-L is for 
learning and helping with programming Lingo.  Thanks!]

Reply via email to