
16
Core Implementation: WinForms
6.3
Add using statements to utilize library
Add a line of code to the class that will utilize IDTechSDK.dll at the start of the file:
using
6.4
Implement the callback function
There is a single method that will receive all callback information from the SDK. It uses DeviceState to determine
which action to take.
private
void
.IDT_DEVICE_Types type, DeviceState state, byte[] data,
IDTTransactionData cardData, EMV_Callback emvCallback, RETURN_CODE transactionResultCode)
{
switch
(state)
{
case
DeviceState.ToConnect:
//A connection attempt is starting for IDT_DEVICE_TYPES type
break
;
case
DeviceState.DefaultDeviceTypeChange:
//The SDK is changing the default device to IDT_DEVICE_TYPES type
break
;
case
DeviceState.Connected:
//A connection has been made to IDT_DEVICE_TYPES type
break
;
#80136501-001 IDTech Windows SDK Guide for Kiosk III/IV