6 Replies Latest reply: Feb 22, 2017 11:39 AM by Marcus Sommer RSS

    File functions not working

    Martyn Lloyd


      I have this script below, FileSize and FileTime are returning data, but FilePath, FileDir, FileExtension are not returning anything - what is wrong?



      DoDir (Root)
      for each Ext in 'bmp', 'jpg', 'png', 'tif'

      for each File in filelist (Root&'\*.' &Ext)
      as [Image Name],
      FilePath('$(File)') as [Image Path],
      FileDir('$(File)') as [Image Dir],
      FileExtension('$(File)') as [Image Ext],
      FileSize('$(File)') as [Image Size],
      FileTime('$(File)') as [Image Time],
      Year(Date(FileTime('$(File)'))) as [Year]

      autogenerate 1;

      next File
      next Ext

      for each Dir in dirlist (Root&'\*' )
      call DoDir (Dir)
      next Dir

      end sub