Xamarin Form - How To store an image in PDF or JPEG Format in UWP

◇◆丶佛笑我妖孽 提交于 2019-12-18 17:34:47

问题


hello friends i am developing the DMS application in which user can scan the document or images through scanner and upload on server.

For scanning purpose i am refered this link it works perfectly..:)

Now problem is ImageScanner.ScanFilesToFolderAsync(ImageScannerScanSource, StorageFolder) this Method accepts the image format which is supported by scanner. my scanner only support the .BMP format but i want to store an image in PDF or JPEG Format in given folder name.

Else please suggest any free pdf package( dll). which accept multiple image format and convert to single pdf format and PDFSharp package support in uwp ?

thanks in advance :)

  ScannerSettings _ScannerSettings = new ScannerSettings();  

  ImageScanner scanner = await ImageScanner.FromIdAsync(_settings.DeviceId);

  scanner = _ScannerSettings.SetScannerSettings(scanner, _settings); // here i am trying to assigning the scanner settings with pdf or jpeg format.

 var operation =  scanner.ScanFilesToFolderAsync(AssignScannerType, folder); // it gives exception if i am passing the pdf or JPEG format in scanner settings because my scanner not support this format.

回答1:


https://github.com/ststeiger/PdfSharpCore is a port for .NET Core 1.6+ It doesn't use System.Drawing.dll. It is based on PdfSharp 1.32 and has some missing and some half-working features.

https://github.com/ststeiger/PdfSharpNetStandard Is for NetStandard 2.1+, and is based on PdfSharp 1.5.

Very few things are missing (https://github.com/ststeiger/PdfSharpNetStandard/tree/master/PdfSharp_Removed https://github.com/ststeiger/PdfSharpNetStandard/tree/master/MigraDoc_Rendering_Removed). PdfSharpNetStandard should work work just like PdfSharp.

PdfSharpCore has changed PdfSharp to be based on the .NET-Core High-Performance implementations. It should have a better/higher performance - in theory.



来源:https://stackoverflow.com/questions/56034495/xamarin-form-how-to-store-an-image-in-pdf-or-jpeg-format-in-uwp

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!