Due to a bug we are unable to debug and run WinUI projects in .net 6.0.100 preview 7.21379.14. It was said that the Visual Studio team will fix this with an update. Temporarily, after you deploy your projects, you can run them without debugging by typing the solution name of the start menu.
To copy specific type of files in one directory with directory information to another directory
You can use 'robocopy' to achieve this.
robocopy e:\source e:\destination *.bmp /s
With /s parameter you can copy all subdiretories.
Last week I had to convert the image files with heic extension on my iPhone to jpg. After researching for a few hours, I learned that the best and cheapest way is to do it myself.
First, we include Magick.NET-Q16-AnyC library in our project via nuget. https://github.com/dlemstra/Magick.NET
Then we take all heic files in the relevant directory and convert them to jpg.
foreach (var item in Directory.GetFiles(@"D:\Apple\105APPLE\", "*.HEIC"))
using (MagickImage image = new MagickImage(item))
var finfo = new FileInfo(item);
// Save frame as jpg
image.Write(@"d:\apple\images\" + finfo.Name.Replace(".HEIC", ".jpg"));
// image.Write(@"d:\apple\images\" + finfo.Name.Replace(".HEIC", ".png"));