Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to Check whether file exists before loading

How to Check whether file exists before loading in qvd from folder which may contain multiple  file of  different name.

multiple csv file is  to be loaded  and deleted after loading . New file can come  daily or may not come causing qvd loading to fail.

Till now written code for laoding from multiple files  and deleted file through macro. but showing error when file is not present in the folder.

3 Replies
swuehl
MVP
MVP

Not applicable
Author

Hi Santosh

You can use Filelist to check the files in directory and FileSize as a check for existence of specific file

Lukasz

maxgro
MVP
MVP

from online help, hope it helps you


filesize()

Returns an integer containing the size in bytes of the file filename or, if no filename is specified, of the table file currently being read.

Examples:

filesize( 'xyz.xls' )

Will return the size of the file xyz.xls.