Пример #1
0
        //Load default Image
        private async void LoadDefaultImageForOcr()
        {
            ProgressVisibility = Visibility.Visible;
            ImageCollection    = new Images();
            ImageCollection    = await FilePickerHelper.GetFileListWithBitmapImages(null, true, new List <string>() { "ms-appx:///Assets/introtext.jpg" });

            if (ImageCollection.ListImageDisplay.Count > 0 && ImageCollection.ListImageDisplay[0].Count > 0)
            {
                ImageDisplay = ImageCollection.ListImageDisplay[0].FirstOrDefault();
                IsOpen       = true;
            }
            else
            {
            }
            ProgressVisibility = Visibility.Collapsed;
        }
Пример #2
0
        private async void ExecutePdfCommand(object obj)
        {
            ProgressVisibility = Visibility.Visible;
            ImageCollection    = new Images();

            List <string> fileTypes = new List <string>();

            fileTypes.Add(".pdf");
            ImageCollection = await FilePickerHelper.GetFileListWithBitmapImages(fileTypes);

            if (ImageCollection.ListImageDisplay.Count > 0 && ImageCollection.ListImageDisplay[0].Count > 0)
            {
                ImageDisplay = ImageCollection.ListImageDisplay[0].FirstOrDefault();//List<ImageSource>
                IsOpen       = true;
            }
            else
            {
            }
            ProgressVisibility = Visibility.Collapsed;
        }