Custom scan settings

As we introduce three kinds on a method using a Dynamic Web TWAIN, you can control the Dynamic Web TWAIN objects in three ways: properties, methods and events. All about Dynamic Web TWAIN built-in properties, methods, and a complete list of events, please see our online API documentation for your reference. Here, we will introduce Dynamic Web TWAIN functions in detail: Before you begin the actual scanning session, you can choose the way the scanned document. Typically, you can change the settings for all built-in scanner user interface.

Before you start the actual scanning session, you can choose the way the scanned document. Typically, you can change the settings for all built-in scanner user interface. Virtual scanner as an example:

On the one hand, the end-user, all of these settings may have been overwhelming, especially for those users without technical background. On the other hand, you may want to scan in the same way all archived documents. Use Dynamic Web TWAIN, you can customize all of these settings in the JavaScript code. E.g:

DWObject.SelectSource();
/* You should customize the settings after opening a source */
DWObject.OpenSource();  
/* Hide the User Interface of the scanner */                
DWObject.IfShowUI = false;     
/* Use the document feeder to scan in batches */      
DWObject.IfFeederEnabled = true;  
/* Scan in Simplex mode (only 1 side of the page) */     
DWObject.IfDuplexEnabled = false;    
/* Scan pages in GRAY */  
DWObject.PixelType = EnumDWT_PixelType.TWPT_GRAY; 
/* Scan pages in 200 DPI */
DWObject.Resolution = 200;   
/* Start scanning */            
DWObject.AcquireImage();  

Related API

BitDepth Brightness Contrast PageSize Resolution
PixelType pixel Flavor IfDuplexEnabled IfFeederEnabled IfShowUI
XferCount IfAutoDiscardBlankpages IfAutomaticDeskew IfAutomaticBorderDetection  
Released two original articles · won praise 4 · Views 4060

Guess you like

Origin blog.csdn.net/weixin_42320186/article/details/81135294