>  Docs Center  >  Libraries  >  JHU/APL/S1R  >  LIBRARIES_FILE_TEST

LIBRARIES_FILE_TEST

LIBRARIES_FILE_TEST

Name


      FILE_TEST

Purpose


      Test if file readable &, optionally, has specified contents.

Category


Calling Sequence


      flag = file_test(file)

Inputs


      file = name of file to check. in

Keyword Parameters


Keywords


        CONTENTS=txt contents of file (text file). Must
          match what's in file or file_test returns 0.

Outputs


      flag = test result, 1=true, 0=false. out

Common Blocks


Notes


      Notes: Useful for testing status type files. Example:
        if file_test('last.tmp',contents='number 3') then begin

Modification History


      R. Sterner, 1996 Sep 26
      R. Sterner, 2010 Jun 04 --- Converted arrays from () to [].
  Copyright (C) 1996, Johns Hopkins University/Applied Physics Laboratory
  This software may be used, copied, or redistributed as long as it is not
  sold and this copyright notice is reproduced on each copy made. This
  routine is provided as is without any express or implied warranties
  whatsoever. Other limitations apply as described in the file disclaimer.txt.



© 2019 Harris Geospatial Solutions, Inc. |  Legal
My Account    |    Store    |    Contact Us