Document Scanner using Dynamic Web TWAIN (DWT) and Blazor
There are two examples: the Basic example and the OCR+Barcode example.
The Basic example just uses DWT to scan documents. The OCR+Barcode example adds barcode reading and OCR functions to the Basic example. Both server and webassembly versions are provided.
Additional steps to run the projects.
- Download Dynamic Web TWAIN and copy its
Resources
folder to thewwwroot
folder. - Modify
dynamsoft.webtwain.config.js
in theResources
folder. Set upProductKey
and changeDynamsoft.DWT.AutoLoad
to false as we want to load DWT manually. You can apply for a free trial license key here. - (optional) You may need to install Windows 10 SDK if you want to use the windows.media.ocr API. Visit here to learn more about using Windows Runtime API in .Net applications.
How to Build a Web Document Scanner with Blazor
There is also a demo running Dynamic Web TWAIN in a WinForms desktop app using BlazorWebView: Combine Blazor and WinForms to Build a Document Scanning Desktop App