I am trying to delete file "c:\Bun272010-06-02T141405.PDF" where the portion after the letter 'T' --'141405' in the filename is the file creation time and this keeps changing whenever the file is created so it cannot be hard-coded.
I tried the codes below using wildcard but that none of them works to delete the files..
Wildcards are not supported in the aqFileSystem.Exists method. See the "aqFileSystem.Exists" article for details.
You can use the aqFileSystem.FindFiles method to find the files whose names will meet the specified search pattern (you can use wildcards there) and delete them. Please refer to the "aqFileSystem.FindFiles" article fore more information.
Best regards, Alexey
Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️