LTwain::EnableDuplex

Summary

Enables or disables the duplex mode.

Syntax

#include "ltwrappr.h"

L_INT LTwain::EnableDuplex (bEnableDuplex)

Parameters

L_BOOL bEnableDuplex

Flag that indicates whether to enable or disable the duplex mode. Possible values are:

Value Meaning
TRUE Enables the duplex mode.
FALSE Disables the duplex mode.

Returns

Value Meaning
SUCCESS The function was successful.
< 1 An error occurred. Refer to Return Codes.

Comments

This function internally sets the duplex enabled capability CAP_DUPLEXENABLED. For more information on these capabilities, refer to the TWAIN specification.

To get the current values of this capability, call the LTwain::GetDuplexOptions function.

Required DLLs and Libraries

See Also

Functions

Topics

Example

L_INT LTwain__EnableDuplexExample(LTwain * plTwain)  
 
{ 
   L_INT    nRet; 
   L_BOOL   bEnableDuplex;  
   L_INT    nDuplexMode;  
   L_INT    nMaxXfer;  
 
   nRet = plTwain->GetDuplexOptions(&bEnableDuplex, &nDuplexMode);  
   if(nRet != SUCCESS) 
      return nRet; 
 
   if (bEnableDuplex != TRUE)  
 
   { 
      nRet = plTwain->EnableDuplex(TRUE);  
      if(nRet != SUCCESS) 
         return nRet; 
   } 
 
   nRet = plTwain->GetMaxXferCount (&nMaxXfer);  
   if(nRet != SUCCESS) 
      return nRet; 
 
   if (nMaxXfer != 10)  
 
   { 
      nRet = plTwain->SetMaxXferCount (10);  
      if(nRet != SUCCESS) 
         return nRet; 
   } 
 
   return SUCCESS; 
} 
Help Version 23.0.2024.2.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS TWAIN C++ Class Library Help
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.