searchname = "DSCF0044"
Set tmp = Database.GetFiles(searchname+"(.jpg|.dng)",True)
'Above gives no error
searchname = "D:\Foto Cache\2015-01-11 PHILIPPINES\2015-01-28 LINGAYEN\test2\DSCF0044"
Set tmp = Database.GetFiles(searchname+"(.jpg|.dng)",True)
This returns: (10090)ActiveX Automation Error "The parameter is incorrect"
What am I doing wrong?
Answer:
I have to replace the "\" by "\\" in my search string in order to have a valid regular expression.
( I finally did remember that I had some kind of error with GetFiles before : topic 2379.
That topic gave me the necessary hint.)