The function Directory("C:\myfolder \*.*", "D") does not find files whose name begins with a tilde ~ (temporary files from the office. ~$.11.2022Test.docx). Why ?
Dear Yuri,
Use Directory( "C:\myfolder *.*", "DH" ) as ~ stands for hidden