如何在Windows文件资源管理器中选择多个文件

时间:2017-01-10 15:33:19

标签: c# xaml uwp

// Set up the file picker.
            Windows.Storage.Pickers.FileOpenPicker openPicker =
           new Windows.Storage.Pickers.FileOpenPicker();
            openPicker.SuggestedStartLocation =
               Windows.Storage.Pickers.PickerLocationId.PicturesLibrary;
            openPicker.ViewMode =
                Windows.Storage.Pickers.PickerViewMode.Thumbnail;


            //Filter to include a sample subset of file types.
            openPicker.FileTypeFilter.Clear();
            openPicker.FileTypeFilter.Add(".png");
            openPicker.FileTypeFilter.Add(".jpeg");
            openPicker.FileTypeFilter.Add(".jpg");

            //Open the file picker.
            Windows.Storage.StorageFile file =
            await openPicker.PickSingleFileAsync();

我想打开Windows资源管理器,选择多个图像,然后复制并粘贴到另一个文件夹。 但是,使用此代码,它并没有帮助我。 enter code here

1 个答案:

答案 0 :(得分:1)

尝试使用多种文件方法。

openPicker.PickMultipleFilesAsync()
相关问题