#include "ltwrappr.h"

virtual L_INT LWia::InitSession(uWiaVersion)

L_UINT uWiaVersion;

the WIA version you wish to use

Initializes the WIA session.

Parameter Description
uWiaVersion The WIA version to be used. Possible values are:
  Value Meaning
  WiaVersion1 [1] Use WIA version 1.
  WiaVersion2 [2] Use WIA version 2.



The function was successful.

< 1

An error occurred. Refer to Return Codes.


This feature is available in LEADTOOLS version 16 or higher.

LWia::InitSession should be called before calling any other LEADTOOLS WIA toolkit function. Likewise, when the handle to the WIA session is no longer needed, it should be freed by calling LWia::EndSession. For every call to LWia::InitSession there must be a call to LWia::EndSession.

Call the LWia::IsAvailable function to determine whether a WIA source is installed, and which version of WIA is being used.


You do not need to call LWia::InitSession if you are using the high-level LWia::AcquireSimple function, since it handles session initialization, session end, and device selection automatically.

Required DLLs and Libraries


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

Help Version 20.0.2019.3.12
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2019 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS WIA C++ Class Library Help