Products | Support | Send comments on this topic. | Email a link to this topic. | Back to Getting Started | Help Version 18.0.10.23
LEADTOOLS TWAIN C DLL Help

L_TwainEnableShowUserInterfaceOnly

Show in webframe

#include "lttwn.h"

L_LTTWN_API L_INT L_TwainEnableShowUserInterfaceOnly (hSession, bEnable)

HTWAINSESSION hSession;

/* handle to an existing TWAIN session */

L_BOOL bEnable;

/* enable flag */

Indicates whether to display the Twain user interface with or without the Scan button, if supported.

Parameter

Description

hSession

Handle to an existing TWAIN session. This handle is obtained by calling the L_TwainInitSession function.

bEnable

Flag that indicates whether to display the user interface.  Possible values are:

 

Value

Meaning

 

TRUE

Display the Twain user interface without the scan button, if supported.

 

FALSE

Display the normal Twain driver user interface with the scan button. (Default)

Returns

SUCCESS

The function was successful.

! = SUCCESS

An error occurred. Refer to Return Codes.

Comments

To display the Twain driver user interface without the scan button, call this function with the bEnable parameter set to true. Then call L_TwainTemplateDlg to display the template dialog.

If you call this function with the bEnable parameter set to false, the template dialog will display the normal Twain user interface, with the scan button.

Required DLLs and Libraries

LTTWN

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

See Also

Function:

L_TwainInitSession, L_TwainTemplateDlg.

Topics:

Handling Template Files

 

TWAIN Functionality: Template File Functions.

Example

static HTWAINSESSION g_hSession;

L_INT TwainEnableShowUserInterfaceOnlyExample(L_TCHAR* pszFileName)
{
   L_INT nRet;
   nRet = L_TwainEnableShowUserInterfaceOnly(g_hSession, TRUE);
   if(nRet != SUCCESS)
      return nRet;
   nRet = L_TwainTemplateDlg(g_hSession, pszFileName, NULL, NULL, NULL);
   if(nRet != SUCCESS)
      return nRet;
   return SUCCESS;
}
Products | Support | Contact Us | Copyright Notices
© 2006-2014 All Rights Reserved. LEAD Technologies, Inc.