Option Strict Off
Option Explicit On
Imports VB = Microsoft.VisualBasic
Friend Class Form1
	Inherits System.Windows.Forms.Form
#Region "Windows Form Designer generated code "
    Public Sub New()
        MyBase.New()
        If m_vb6FormDefInstance Is Nothing Then
            If m_InitializingDefInstance Then
                m_vb6FormDefInstance = Me
            Else
                Try
                    If System.Reflection.Assembly.GetExecutingAssembly.EntryPoint.DeclaringType Is Me.GetType Then
                        m_vb6FormDefInstance = Me
                    End If
                Catch
                End Try
            End If
        End If
        InitializeComponent()
    End Sub
    Protected Overloads Overrides Sub Dispose(ByVal Disposing As Boolean)
        If Disposing Then
            If Not components Is Nothing Then
                components.Dispose()
            End If
        End If
        MyBase.Dispose(Disposing)
    End Sub
    Private components As System.ComponentModel.IContainer
    Public WithEvents Unit_Check As System.Windows.Forms.CheckBox
    Public WithEvents Frame10 As System.Windows.Forms.GroupBox
    Public WithEvents Frame6 As System.Windows.Forms.GroupBox
    Public WithEvents Combo1 As System.Windows.Forms.ComboBox
    Public WithEvents cmd_get As System.Windows.Forms.Button
    Public WithEvents Frame7 As System.Windows.Forms.GroupBox
    Public WithEvents Text_Contrast As System.Windows.Forms.TextBox
    Public WithEvents Text_shadow As System.Windows.Forms.TextBox
    Public WithEvents Text_Highlight As System.Windows.Forms.TextBox
    Public WithEvents Text_Gamma As System.Windows.Forms.TextBox
    Public WithEvents Text_Bright As System.Windows.Forms.TextBox
    Public WithEvents Text_Thres As System.Windows.Forms.TextBox
    Public WithEvents Frame5 As System.Windows.Forms.GroupBox
    Public WithEvents Text_Cnt As System.Windows.Forms.TextBox
    Public WithEvents _Label1_1 As System.Windows.Forms.Label
    Public WithEvents Frame9 As System.Windows.Forms.GroupBox
    Public WithEvents Frame4 As System.Windows.Forms.GroupBox
    Public WithEvents Text_Bit As System.Windows.Forms.TextBox
    Public WithEvents Label2 As System.Windows.Forms.Label
    Public WithEvents Frame2 As System.Windows.Forms.GroupBox
    Public WithEvents Thumb_Check As System.Windows.Forms.CheckBox
    Public WithEvents Text_Dpi As System.Windows.Forms.TextBox
    Public WithEvents Label4 As System.Windows.Forms.Label
    Public WithEvents Frame1 As System.Windows.Forms.GroupBox
    Public WithEvents Frame3 As System.Windows.Forms.GroupBox

    Friend WithEvents ProgressBar1 As System.Windows.Forms.ProgressBar
    Public WithEvents opt_feed_2 As System.Windows.Forms.RadioButton
    Public WithEvents opt_feed_1 As System.Windows.Forms.RadioButton
    Public WithEvents opt_feed_0 As System.Windows.Forms.RadioButton
    Public WithEvents opt_pixel_0 As System.Windows.Forms.RadioButton
    Public WithEvents opt_pixel_1 As System.Windows.Forms.RadioButton
    Public WithEvents opt_pixel_2 As System.Windows.Forms.RadioButton
    Public WithEvents opt_pixel_3 As System.Windows.Forms.RadioButton
    Public WithEvents opt_device_0 As System.Windows.Forms.RadioButton
    Public WithEvents opt_device_1 As System.Windows.Forms.RadioButton
    Public WithEvents opt_size_0 As System.Windows.Forms.RadioButton
    Public WithEvents opt_size_1 As System.Windows.Forms.RadioButton
    Public WithEvents opt_size_2 As System.Windows.Forms.RadioButton
    Friend WithEvents ImageKit1 As AxIMAGEKIT7Lib.AxImageKit
    Public WithEvents opt_meter_0 As System.Windows.Forms.RadioButton
    Public WithEvents opt_meter_1 As System.Windows.Forms.RadioButton
    Friend WithEvents MenuItem1 As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem3 As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem5 As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem6 As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem7 As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem12 As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem13 As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem14 As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem18 As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_SelectSource As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_OpenDS As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_CloseDS As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Exec As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Exit As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Native As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Memory As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_DisplayUI As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_DisplayUI_C As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_DisableUI As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Contrast As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Gamma As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Highlight As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Shadow As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_XRes As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_YRes As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Threshold As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_XScale As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_YScale As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Compression As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_PixelType As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Unit As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Trans As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Orientation As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_HalfTones As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Paper As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Bit As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_BitDepthReduction As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Feeder As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_FeederLoad As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Indicator As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Online As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Thumbnails As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Duplex As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_ImageNum As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_MaxSize As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_MinSize As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Current As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_ComboBoxt As System.Windows.Forms.MenuItem
    Friend WithEvents MenuItem52 As System.Windows.Forms.MenuItem
    Public WithEvents opt_unit_2 As System.Windows.Forms.RadioButton
    Public WithEvents opt_unit_0 As System.Windows.Forms.RadioButton
    Public WithEvents opt_unit_1 As System.Windows.Forms.RadioButton
    Friend WithEvents Menu_hanni As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_Brightness As System.Windows.Forms.MenuItem
    Friend WithEvents Menu_ControllUI As System.Windows.Forms.MenuItem
    Public WithEvents Label3_5 As System.Windows.Forms.Label
    Public WithEvents Label3_3 As System.Windows.Forms.Label
    Public WithEvents Label3_2 As System.Windows.Forms.Label
    Public WithEvents Label3_1 As System.Windows.Forms.Label
    Public WithEvents Label3_0 As System.Windows.Forms.Label
    Public WithEvents Label3_4 As System.Windows.Forms.Label
    Public WithEvents MainMenu1 As System.Windows.Forms.MainMenu
    Friend WithEvents TextBox1 As System.Windows.Forms.TextBox

    'NOTE: The following procedure is required by the Windows Form Designer
    'It can be modified using the Windows Form Designer.
    'Do not modify it using the code editor.
    <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
        Dim resources As System.Resources.ResourceManager = New System.Resources.ResourceManager(GetType(Form1))
        Me.Frame10 = New System.Windows.Forms.GroupBox
        Me.Unit_Check = New System.Windows.Forms.CheckBox
        Me.opt_unit_2 = New System.Windows.Forms.RadioButton
        Me.opt_unit_0 = New System.Windows.Forms.RadioButton
        Me.opt_unit_1 = New System.Windows.Forms.RadioButton
        Me.Frame6 = New System.Windows.Forms.GroupBox
        Me.opt_meter_0 = New System.Windows.Forms.RadioButton
        Me.opt_meter_1 = New System.Windows.Forms.RadioButton
        Me.Frame7 = New System.Windows.Forms.GroupBox
        Me.Combo1 = New System.Windows.Forms.ComboBox
        Me.cmd_get = New System.Windows.Forms.Button
        Me.Text_Contrast = New System.Windows.Forms.TextBox
        Me.Frame5 = New System.Windows.Forms.GroupBox
        Me.Text_shadow = New System.Windows.Forms.TextBox
        Me.Text_Highlight = New System.Windows.Forms.TextBox
        Me.Text_Gamma = New System.Windows.Forms.TextBox
        Me.Text_Bright = New System.Windows.Forms.TextBox
        Me.Text_Thres = New System.Windows.Forms.TextBox
        Me.Label3_5 = New System.Windows.Forms.Label
        Me.Label3_3 = New System.Windows.Forms.Label
        Me.Label3_2 = New System.Windows.Forms.Label
        Me.Label3_1 = New System.Windows.Forms.Label
        Me.Label3_0 = New System.Windows.Forms.Label
        Me.Label3_4 = New System.Windows.Forms.Label
        Me.Frame9 = New System.Windows.Forms.GroupBox
        Me.ImageKit1 = New AxIMAGEKIT7Lib.AxImageKit
        Me.Text_Cnt = New System.Windows.Forms.TextBox
        Me._Label1_1 = New System.Windows.Forms.Label
        Me.Frame4 = New System.Windows.Forms.GroupBox
        Me.opt_feed_2 = New System.Windows.Forms.RadioButton
        Me.opt_feed_1 = New System.Windows.Forms.RadioButton
        Me.opt_feed_0 = New System.Windows.Forms.RadioButton
        Me.Frame2 = New System.Windows.Forms.GroupBox
        Me.Text_Bit = New System.Windows.Forms.TextBox
        Me.opt_pixel_0 = New System.Windows.Forms.RadioButton
        Me.opt_pixel_1 = New System.Windows.Forms.RadioButton
        Me.opt_pixel_2 = New System.Windows.Forms.RadioButton
        Me.opt_pixel_3 = New System.Windows.Forms.RadioButton
        Me.Label2 = New System.Windows.Forms.Label
        Me.Frame1 = New System.Windows.Forms.GroupBox
        Me.Thumb_Check = New System.Windows.Forms.CheckBox
        Me.Text_Dpi = New System.Windows.Forms.TextBox
        Me.opt_device_0 = New System.Windows.Forms.RadioButton
        Me.opt_device_1 = New System.Windows.Forms.RadioButton
        Me.Label4 = New System.Windows.Forms.Label
        Me.Frame3 = New System.Windows.Forms.GroupBox
        Me.opt_size_0 = New System.Windows.Forms.RadioButton
        Me.opt_size_1 = New System.Windows.Forms.RadioButton
        Me.opt_size_2 = New System.Windows.Forms.RadioButton
        Me.ProgressBar1 = New System.Windows.Forms.ProgressBar
        Me.MainMenu1 = New System.Windows.Forms.MainMenu
        Me.MenuItem1 = New System.Windows.Forms.MenuItem
        Me.Menu_SelectSource = New System.Windows.Forms.MenuItem
        Me.MenuItem12 = New System.Windows.Forms.MenuItem
        Me.Menu_OpenDS = New System.Windows.Forms.MenuItem
        Me.Menu_CloseDS = New System.Windows.Forms.MenuItem
        Me.MenuItem13 = New System.Windows.Forms.MenuItem
        Me.Menu_Exec = New System.Windows.Forms.MenuItem
        Me.MenuItem14 = New System.Windows.Forms.MenuItem
        Me.Menu_Exit = New System.Windows.Forms.MenuItem
        Me.MenuItem3 = New System.Windows.Forms.MenuItem
        Me.Menu_Native = New System.Windows.Forms.MenuItem
        Me.Menu_Memory = New System.Windows.Forms.MenuItem
        Me.MenuItem18 = New System.Windows.Forms.MenuItem
        Me.Menu_DisplayUI = New System.Windows.Forms.MenuItem
        Me.Menu_DisplayUI_C = New System.Windows.Forms.MenuItem
        Me.Menu_DisableUI = New System.Windows.Forms.MenuItem
        Me.Menu_hanni = New System.Windows.Forms.MenuItem
        Me.Menu_Brightness = New System.Windows.Forms.MenuItem
        Me.Menu_Contrast = New System.Windows.Forms.MenuItem
        Me.Menu_Gamma = New System.Windows.Forms.MenuItem
        Me.Menu_Highlight = New System.Windows.Forms.MenuItem
        Me.Menu_Shadow = New System.Windows.Forms.MenuItem
        Me.Menu_XRes = New System.Windows.Forms.MenuItem
        Me.Menu_YRes = New System.Windows.Forms.MenuItem
        Me.Menu_Threshold = New System.Windows.Forms.MenuItem
        Me.Menu_XScale = New System.Windows.Forms.MenuItem
        Me.Menu_YScale = New System.Windows.Forms.MenuItem
        Me.MenuItem5 = New System.Windows.Forms.MenuItem
        Me.Menu_Compression = New System.Windows.Forms.MenuItem
        Me.Menu_PixelType = New System.Windows.Forms.MenuItem
        Me.Menu_Unit = New System.Windows.Forms.MenuItem
        Me.Menu_Trans = New System.Windows.Forms.MenuItem
        Me.Menu_Orientation = New System.Windows.Forms.MenuItem
        Me.Menu_HalfTones = New System.Windows.Forms.MenuItem
        Me.Menu_Paper = New System.Windows.Forms.MenuItem
        Me.Menu_Bit = New System.Windows.Forms.MenuItem
        Me.Menu_BitDepthReduction = New System.Windows.Forms.MenuItem
        Me.MenuItem6 = New System.Windows.Forms.MenuItem
        Me.Menu_Feeder = New System.Windows.Forms.MenuItem
        Me.Menu_FeederLoad = New System.Windows.Forms.MenuItem
        Me.Menu_Indicator = New System.Windows.Forms.MenuItem
        Me.Menu_ControllUI = New System.Windows.Forms.MenuItem
        Me.Menu_Online = New System.Windows.Forms.MenuItem
        Me.Menu_Thumbnails = New System.Windows.Forms.MenuItem
        Me.Menu_Duplex = New System.Windows.Forms.MenuItem
        Me.Menu_ImageNum = New System.Windows.Forms.MenuItem
        Me.Menu_MaxSize = New System.Windows.Forms.MenuItem
        Me.Menu_MinSize = New System.Windows.Forms.MenuItem
        Me.MenuItem7 = New System.Windows.Forms.MenuItem
        Me.Menu_Current = New System.Windows.Forms.MenuItem
        Me.Menu_ComboBoxt = New System.Windows.Forms.MenuItem
        Me.MenuItem52 = New System.Windows.Forms.MenuItem
        Me.TextBox1 = New System.Windows.Forms.TextBox
        Me.Frame10.SuspendLayout()
        Me.Frame6.SuspendLayout()
        Me.Frame7.SuspendLayout()
        Me.Frame5.SuspendLayout()
        Me.Frame9.SuspendLayout()
        CType(Me.ImageKit1, System.ComponentModel.ISupportInitialize).BeginInit()
        Me.Frame4.SuspendLayout()
        Me.Frame2.SuspendLayout()
        Me.Frame1.SuspendLayout()
        Me.Frame3.SuspendLayout()
        Me.SuspendLayout()
        '
        'Frame10
        '
        Me.Frame10.BackColor = System.Drawing.SystemColors.Control
        Me.Frame10.Controls.Add(Me.Unit_Check)
        Me.Frame10.Controls.Add(Me.opt_unit_2)
        Me.Frame10.Controls.Add(Me.opt_unit_0)
        Me.Frame10.Controls.Add(Me.opt_unit_1)
        Me.Frame10.Font = New System.Drawing.Font("Arial", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(128, Byte))
        Me.Frame10.ForeColor = System.Drawing.Color.Blue
        Me.Frame10.Location = New System.Drawing.Point(16, 432)
        Me.Frame10.Name = "Frame10"
        Me.Frame10.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame10.Size = New System.Drawing.Size(217, 102)
        Me.Frame10.TabIndex = 19
        Me.Frame10.TabStop = False
        Me.Frame10.Text = "Units of Measure"
        '
        'Unit_Check
        '
        Me.Unit_Check.BackColor = System.Drawing.SystemColors.Control
        Me.Unit_Check.Cursor = System.Windows.Forms.Cursors.Default
        Me.Unit_Check.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Unit_Check.Location = New System.Drawing.Point(112, 17)
        Me.Unit_Check.Name = "Unit_Check"
        Me.Unit_Check.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Unit_Check.Size = New System.Drawing.Size(89, 27)
        Me.Unit_Check.TabIndex = 47
        Me.Unit_Check.Text = "IK Mode"
        '
        'opt_unit_2
        '
        Me.opt_unit_2.BackColor = System.Drawing.SystemColors.Control
        Me.opt_unit_2.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_unit_2.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_unit_2.Location = New System.Drawing.Point(12, 72)
        Me.opt_unit_2.Name = "opt_unit_2"
        Me.opt_unit_2.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_unit_2.Size = New System.Drawing.Size(93, 22)
        Me.opt_unit_2.TabIndex = 45
        Me.opt_unit_2.TabStop = True
        Me.opt_unit_2.Text = "Pixel"
        '
        'opt_unit_0
        '
        Me.opt_unit_0.BackColor = System.Drawing.SystemColors.Control
        Me.opt_unit_0.Checked = True
        Me.opt_unit_0.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_unit_0.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_unit_0.Location = New System.Drawing.Point(12, 17)
        Me.opt_unit_0.Name = "opt_unit_0"
        Me.opt_unit_0.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_unit_0.Size = New System.Drawing.Size(73, 19)
        Me.opt_unit_0.TabIndex = 20
        Me.opt_unit_0.TabStop = True
        Me.opt_unit_0.Text = "Inch"
        '
        'opt_unit_1
        '
        Me.opt_unit_1.BackColor = System.Drawing.SystemColors.Control
        Me.opt_unit_1.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_unit_1.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_unit_1.Location = New System.Drawing.Point(12, 42)
        Me.opt_unit_1.Name = "opt_unit_1"
        Me.opt_unit_1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_unit_1.Size = New System.Drawing.Size(93, 23)
        Me.opt_unit_1.TabIndex = 21
        Me.opt_unit_1.TabStop = True
        Me.opt_unit_1.Text = "Centimeter"
        '
        'Frame6
        '
        Me.Frame6.BackColor = System.Drawing.SystemColors.Control
        Me.Frame6.Controls.Add(Me.opt_meter_0)
        Me.Frame6.Controls.Add(Me.opt_meter_1)
        Me.Frame6.Font = New System.Drawing.Font("Arial", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(128, Byte))
        Me.Frame6.ForeColor = System.Drawing.Color.Blue
        Me.Frame6.Location = New System.Drawing.Point(256, 304)
        Me.Frame6.Name = "Frame6"
        Me.Frame6.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame6.Size = New System.Drawing.Size(185, 70)
        Me.Frame6.TabIndex = 29
        Me.Frame6.TabStop = False
        Me.Frame6.Text = "Indicator"
        '
        'opt_meter_0
        '
        Me.opt_meter_0.BackColor = System.Drawing.SystemColors.Control
        Me.opt_meter_0.Checked = True
        Me.opt_meter_0.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_meter_0.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_meter_0.Location = New System.Drawing.Point(20, 17)
        Me.opt_meter_0.Name = "opt_meter_0"
        Me.opt_meter_0.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_meter_0.Size = New System.Drawing.Size(144, 19)
        Me.opt_meter_0.TabIndex = 30
        Me.opt_meter_0.TabStop = True
        Me.opt_meter_0.Text = "Not Displayed"
        '
        'opt_meter_1
        '
        Me.opt_meter_1.BackColor = System.Drawing.SystemColors.Control
        Me.opt_meter_1.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_meter_1.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_meter_1.Location = New System.Drawing.Point(20, 43)
        Me.opt_meter_1.Name = "opt_meter_1"
        Me.opt_meter_1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_meter_1.Size = New System.Drawing.Size(144, 23)
        Me.opt_meter_1.TabIndex = 31
        Me.opt_meter_1.TabStop = True
        Me.opt_meter_1.Text = "Displayed"
        '
        'Frame7
        '
        Me.Frame7.BackColor = System.Drawing.SystemColors.Control
        Me.Frame7.Controls.Add(Me.Combo1)
        Me.Frame7.Controls.Add(Me.cmd_get)
        Me.Frame7.ForeColor = System.Drawing.Color.Blue
        Me.Frame7.Location = New System.Drawing.Point(256, 388)
        Me.Frame7.Name = "Frame7"
        Me.Frame7.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame7.Size = New System.Drawing.Size(185, 105)
        Me.Frame7.TabIndex = 32
        Me.Frame7.TabStop = False
        Me.Frame7.Text = "TWAIN Source"
        '
        'Combo1
        '
        Me.Combo1.BackColor = System.Drawing.SystemColors.Window
        Me.Combo1.Cursor = System.Windows.Forms.Cursors.Default
        Me.Combo1.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Combo1.Location = New System.Drawing.Point(8, 61)
        Me.Combo1.Name = "Combo1"
        Me.Combo1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Combo1.Size = New System.Drawing.Size(169, 21)
        Me.Combo1.Sorted = True
        Me.Combo1.TabIndex = 34
        '
        'cmd_get
        '
        Me.cmd_get.BackColor = System.Drawing.SystemColors.Control
        Me.cmd_get.Cursor = System.Windows.Forms.Cursors.Default
        Me.cmd_get.ForeColor = System.Drawing.SystemColors.ControlText
        Me.cmd_get.Location = New System.Drawing.Point(16, 17)
        Me.cmd_get.Name = "cmd_get"
        Me.cmd_get.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.cmd_get.Size = New System.Drawing.Size(80, 27)
        Me.cmd_get.TabIndex = 33
        Me.cmd_get.Text = "Get Device"
        '
        'Text_Contrast
        '
        Me.Text_Contrast.AcceptsReturn = True
        Me.Text_Contrast.AutoSize = False
        Me.Text_Contrast.BackColor = System.Drawing.SystemColors.Window
        Me.Text_Contrast.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_Contrast.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_Contrast.Location = New System.Drawing.Point(352, 148)
        Me.Text_Contrast.MaxLength = 0
        Me.Text_Contrast.Name = "Text_Contrast"
        Me.Text_Contrast.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_Contrast.Size = New System.Drawing.Size(41, 19)
        Me.Text_Contrast.TabIndex = 25
        Me.Text_Contrast.Text = "0"
        Me.Text_Contrast.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        'Frame5
        '
        Me.Frame5.BackColor = System.Drawing.SystemColors.Control
        Me.Frame5.Controls.Add(Me.Text_shadow)
        Me.Frame5.Controls.Add(Me.Text_Highlight)
        Me.Frame5.Controls.Add(Me.Text_Gamma)
        Me.Frame5.Controls.Add(Me.Text_Bright)
        Me.Frame5.Controls.Add(Me.Text_Thres)
        Me.Frame5.Controls.Add(Me.Label3_5)
        Me.Frame5.Controls.Add(Me.Label3_3)
        Me.Frame5.Controls.Add(Me.Label3_2)
        Me.Frame5.Controls.Add(Me.Label3_1)
        Me.Frame5.Controls.Add(Me.Label3_0)
        Me.Frame5.Controls.Add(Me.Label3_4)
        Me.Frame5.ForeColor = System.Drawing.Color.Blue
        Me.Frame5.Location = New System.Drawing.Point(256, 96)
        Me.Frame5.Name = "Frame5"
        Me.Frame5.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame5.Size = New System.Drawing.Size(185, 191)
        Me.Frame5.TabIndex = 22
        Me.Frame5.TabStop = False
        Me.Frame5.Text = "Image Info"
        '
        'Text_shadow
        '
        Me.Text_shadow.AcceptsReturn = True
        Me.Text_shadow.AutoSize = False
        Me.Text_shadow.BackColor = System.Drawing.SystemColors.Window
        Me.Text_shadow.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_shadow.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_shadow.Location = New System.Drawing.Point(96, 156)
        Me.Text_shadow.MaxLength = 0
        Me.Text_shadow.Name = "Text_shadow"
        Me.Text_shadow.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_shadow.Size = New System.Drawing.Size(41, 20)
        Me.Text_shadow.TabIndex = 28
        Me.Text_shadow.Text = "0"
        Me.Text_shadow.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        'Text_Highlight
        '
        Me.Text_Highlight.AcceptsReturn = True
        Me.Text_Highlight.AutoSize = False
        Me.Text_Highlight.BackColor = System.Drawing.SystemColors.Window
        Me.Text_Highlight.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_Highlight.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_Highlight.Location = New System.Drawing.Point(96, 104)
        Me.Text_Highlight.MaxLength = 0
        Me.Text_Highlight.Name = "Text_Highlight"
        Me.Text_Highlight.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_Highlight.Size = New System.Drawing.Size(41, 20)
        Me.Text_Highlight.TabIndex = 26
        Me.Text_Highlight.Text = "255"
        Me.Text_Highlight.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        'Text_Gamma
        '
        Me.Text_Gamma.AcceptsReturn = True
        Me.Text_Gamma.AutoSize = False
        Me.Text_Gamma.BackColor = System.Drawing.SystemColors.Window
        Me.Text_Gamma.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_Gamma.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_Gamma.Location = New System.Drawing.Point(96, 78)
        Me.Text_Gamma.MaxLength = 0
        Me.Text_Gamma.Name = "Text_Gamma"
        Me.Text_Gamma.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_Gamma.Size = New System.Drawing.Size(41, 20)
        Me.Text_Gamma.TabIndex = 24
        Me.Text_Gamma.Text = "2.2"
        Me.Text_Gamma.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        'Text_Bright
        '
        Me.Text_Bright.AcceptsReturn = True
        Me.Text_Bright.AutoSize = False
        Me.Text_Bright.BackColor = System.Drawing.SystemColors.Window
        Me.Text_Bright.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_Bright.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_Bright.Location = New System.Drawing.Point(96, 26)
        Me.Text_Bright.MaxLength = 0
        Me.Text_Bright.Name = "Text_Bright"
        Me.Text_Bright.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_Bright.Size = New System.Drawing.Size(41, 20)
        Me.Text_Bright.TabIndex = 23
        Me.Text_Bright.Text = "0"
        Me.Text_Bright.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        'Text_Thres
        '
        Me.Text_Thres.AcceptsReturn = True
        Me.Text_Thres.AutoSize = False
        Me.Text_Thres.BackColor = System.Drawing.SystemColors.Window
        Me.Text_Thres.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_Thres.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_Thres.Location = New System.Drawing.Point(96, 130)
        Me.Text_Thres.MaxLength = 0
        Me.Text_Thres.Name = "Text_Thres"
        Me.Text_Thres.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_Thres.Size = New System.Drawing.Size(41, 20)
        Me.Text_Thres.TabIndex = 27
        Me.Text_Thres.Text = "128"
        Me.Text_Thres.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        'Label3_5
        '
        Me.Label3_5.BackColor = System.Drawing.SystemColors.Control
        Me.Label3_5.Cursor = System.Windows.Forms.Cursors.Default
        Me.Label3_5.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Label3_5.Location = New System.Drawing.Point(16, 156)
        Me.Label3_5.Name = "Label3_5"
        Me.Label3_5.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Label3_5.Size = New System.Drawing.Size(65, 18)
        Me.Label3_5.TabIndex = 44
        Me.Label3_5.Text = "Shadow"
        '
        'Label3_3
        '
        Me.Label3_3.BackColor = System.Drawing.SystemColors.Control
        Me.Label3_3.Cursor = System.Windows.Forms.Cursors.Default
        Me.Label3_3.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Label3_3.Location = New System.Drawing.Point(16, 104)
        Me.Label3_3.Name = "Label3_3"
        Me.Label3_3.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Label3_3.Size = New System.Drawing.Size(65, 18)
        Me.Label3_3.TabIndex = 43
        Me.Label3_3.Text = "Highlight"
        '
        'Label3_2
        '
        Me.Label3_2.BackColor = System.Drawing.SystemColors.Control
        Me.Label3_2.Cursor = System.Windows.Forms.Cursors.Default
        Me.Label3_2.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Label3_2.Location = New System.Drawing.Point(16, 78)
        Me.Label3_2.Name = "Label3_2"
        Me.Label3_2.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Label3_2.Size = New System.Drawing.Size(65, 18)
        Me.Label3_2.TabIndex = 42
        Me.Label3_2.Text = "Gamma"
        '
        'Label3_1
        '
        Me.Label3_1.BackColor = System.Drawing.SystemColors.Control
        Me.Label3_1.Cursor = System.Windows.Forms.Cursors.Default
        Me.Label3_1.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Label3_1.Location = New System.Drawing.Point(16, 52)
        Me.Label3_1.Name = "Label3_1"
        Me.Label3_1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Label3_1.Size = New System.Drawing.Size(65, 18)
        Me.Label3_1.TabIndex = 41
        Me.Label3_1.Text = "Contrast"
        '
        'Label3_0
        '
        Me.Label3_0.BackColor = System.Drawing.SystemColors.Control
        Me.Label3_0.Cursor = System.Windows.Forms.Cursors.Default
        Me.Label3_0.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Label3_0.Location = New System.Drawing.Point(16, 26)
        Me.Label3_0.Name = "Label3_0"
        Me.Label3_0.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Label3_0.Size = New System.Drawing.Size(65, 18)
        Me.Label3_0.TabIndex = 40
        Me.Label3_0.Text = "Brightness"
        '
        'Label3_4
        '
        Me.Label3_4.BackColor = System.Drawing.SystemColors.Control
        Me.Label3_4.Cursor = System.Windows.Forms.Cursors.Default
        Me.Label3_4.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Label3_4.Location = New System.Drawing.Point(16, 130)
        Me.Label3_4.Name = "Label3_4"
        Me.Label3_4.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Label3_4.Size = New System.Drawing.Size(57, 18)
        Me.Label3_4.TabIndex = 39
        Me.Label3_4.Text = "Threshold"
        '
        'Frame9
        '
        Me.Frame9.BackColor = System.Drawing.SystemColors.Control
        Me.Frame9.Controls.Add(Me.ImageKit1)
        Me.Frame9.Controls.Add(Me.Text_Cnt)
        Me.Frame9.Controls.Add(Me._Label1_1)
        Me.Frame9.ForeColor = System.Drawing.Color.FromArgb(CType(192, Byte), CType(0, Byte), CType(0, Byte))
        Me.Frame9.Location = New System.Drawing.Point(16, 540)
        Me.Frame9.Name = "Frame9"
        Me.Frame9.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame9.Size = New System.Drawing.Size(217, 131)
        Me.Frame9.TabIndex = 35
        Me.Frame9.TabStop = False
        Me.Frame9.Text = "Scan Info"
        '
        'ImageKit1
        '
        Me.ImageKit1.ContainingControl = Me
        Me.ImageKit1.Location = New System.Drawing.Point(92, 22)
        Me.ImageKit1.Name = "ImageKit1"
        Me.ImageKit1.OcxState = CType(resources.GetObject("ImageKit1.OcxState"), System.Windows.Forms.AxHost.State)
        Me.ImageKit1.Size = New System.Drawing.Size(116, 99)
        Me.ImageKit1.TabIndex = 38
        '
        'Text_Cnt
        '
        Me.Text_Cnt.AcceptsReturn = True
        Me.Text_Cnt.AutoSize = False
        Me.Text_Cnt.BackColor = System.Drawing.SystemColors.Window
        Me.Text_Cnt.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_Cnt.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_Cnt.Location = New System.Drawing.Point(12, 69)
        Me.Text_Cnt.MaxLength = 0
        Me.Text_Cnt.Name = "Text_Cnt"
        Me.Text_Cnt.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_Cnt.Size = New System.Drawing.Size(49, 20)
        Me.Text_Cnt.TabIndex = 37
        Me.Text_Cnt.Text = ""
        Me.Text_Cnt.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        '_Label1_1
        '
        Me._Label1_1.BackColor = System.Drawing.SystemColors.Control
        Me._Label1_1.Cursor = System.Windows.Forms.Cursors.Default
        Me._Label1_1.ForeColor = System.Drawing.SystemColors.ControlText
        Me._Label1_1.Location = New System.Drawing.Point(8, 26)
        Me._Label1_1.Name = "_Label1_1"
        Me._Label1_1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me._Label1_1.Size = New System.Drawing.Size(65, 39)
        Me._Label1_1.TabIndex = 36
        Me._Label1_1.Text = "Number of Pages Scanned"
        '
        'Frame4
        '
        Me.Frame4.BackColor = System.Drawing.SystemColors.Control
        Me.Frame4.Controls.Add(Me.opt_feed_2)
        Me.Frame4.Controls.Add(Me.opt_feed_1)
        Me.Frame4.Controls.Add(Me.opt_feed_0)
        Me.Frame4.Font = New System.Drawing.Font("Arial", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(128, Byte))
        Me.Frame4.ForeColor = System.Drawing.Color.Blue
        Me.Frame4.Location = New System.Drawing.Point(108, 320)
        Me.Frame4.Name = "Frame4"
        Me.Frame4.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame4.Size = New System.Drawing.Size(124, 101)
        Me.Frame4.TabIndex = 15
        Me.Frame4.TabStop = False
        Me.Frame4.Text = "Feed"
        '
        'opt_feed_2
        '
        Me.opt_feed_2.BackColor = System.Drawing.SystemColors.Control
        Me.opt_feed_2.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_feed_2.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_feed_2.Location = New System.Drawing.Point(4, 69)
        Me.opt_feed_2.Name = "opt_feed_2"
        Me.opt_feed_2.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_feed_2.Size = New System.Drawing.Size(116, 23)
        Me.opt_feed_2.TabIndex = 18
        Me.opt_feed_2.TabStop = True
        Me.opt_feed_2.Text = "ADF DoubleSide"
        '
        'opt_feed_1
        '
        Me.opt_feed_1.BackColor = System.Drawing.SystemColors.Control
        Me.opt_feed_1.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_feed_1.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_feed_1.Location = New System.Drawing.Point(4, 43)
        Me.opt_feed_1.Name = "opt_feed_1"
        Me.opt_feed_1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_feed_1.Size = New System.Drawing.Size(116, 23)
        Me.opt_feed_1.TabIndex = 17
        Me.opt_feed_1.TabStop = True
        Me.opt_feed_1.Text = "ADF SingleSide"
        '
        'opt_feed_0
        '
        Me.opt_feed_0.BackColor = System.Drawing.SystemColors.Control
        Me.opt_feed_0.Checked = True
        Me.opt_feed_0.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_feed_0.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_feed_0.Location = New System.Drawing.Point(4, 18)
        Me.opt_feed_0.Name = "opt_feed_0"
        Me.opt_feed_0.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_feed_0.Size = New System.Drawing.Size(116, 19)
        Me.opt_feed_0.TabIndex = 16
        Me.opt_feed_0.TabStop = True
        Me.opt_feed_0.Text = "Document Plate"
        '
        'Frame2
        '
        Me.Frame2.BackColor = System.Drawing.SystemColors.Control
        Me.Frame2.Controls.Add(Me.Text_Bit)
        Me.Frame2.Controls.Add(Me.opt_pixel_0)
        Me.Frame2.Controls.Add(Me.opt_pixel_1)
        Me.Frame2.Controls.Add(Me.opt_pixel_2)
        Me.Frame2.Controls.Add(Me.opt_pixel_3)
        Me.Frame2.Controls.Add(Me.Label2)
        Me.Frame2.Font = New System.Drawing.Font("Arial", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(128, Byte))
        Me.Frame2.ForeColor = System.Drawing.Color.Blue
        Me.Frame2.Location = New System.Drawing.Point(16, 180)
        Me.Frame2.Name = "Frame2"
        Me.Frame2.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame2.Size = New System.Drawing.Size(217, 131)
        Me.Frame2.TabIndex = 5
        Me.Frame2.TabStop = False
        Me.Frame2.Text = "Pixel Type"
        '
        'Text_Bit
        '
        Me.Text_Bit.AcceptsReturn = True
        Me.Text_Bit.AutoSize = False
        Me.Text_Bit.BackColor = System.Drawing.SystemColors.Window
        Me.Text_Bit.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_Bit.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_Bit.Location = New System.Drawing.Point(168, 24)
        Me.Text_Bit.MaxLength = 0
        Me.Text_Bit.Name = "Text_Bit"
        Me.Text_Bit.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_Bit.Size = New System.Drawing.Size(41, 19)
        Me.Text_Bit.TabIndex = 10
        Me.Text_Bit.Text = "1"
        Me.Text_Bit.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        'opt_pixel_0
        '
        Me.opt_pixel_0.BackColor = System.Drawing.SystemColors.Control
        Me.opt_pixel_0.Checked = True
        Me.opt_pixel_0.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_pixel_0.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_pixel_0.Location = New System.Drawing.Point(12, 18)
        Me.opt_pixel_0.Name = "opt_pixel_0"
        Me.opt_pixel_0.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_pixel_0.Size = New System.Drawing.Size(85, 28)
        Me.opt_pixel_0.TabIndex = 6
        Me.opt_pixel_0.TabStop = True
        Me.opt_pixel_0.Text = "1Bit Color"
        '
        'opt_pixel_1
        '
        Me.opt_pixel_1.BackColor = System.Drawing.SystemColors.Control
        Me.opt_pixel_1.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_pixel_1.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_pixel_1.Location = New System.Drawing.Point(12, 43)
        Me.opt_pixel_1.Name = "opt_pixel_1"
        Me.opt_pixel_1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_pixel_1.Size = New System.Drawing.Size(92, 27)
        Me.opt_pixel_1.TabIndex = 7
        Me.opt_pixel_1.TabStop = True
        Me.opt_pixel_1.Text = "Grayscale"
        '
        'opt_pixel_2
        '
        Me.opt_pixel_2.BackColor = System.Drawing.SystemColors.Control
        Me.opt_pixel_2.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_pixel_2.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_pixel_2.Location = New System.Drawing.Point(12, 69)
        Me.opt_pixel_2.Name = "opt_pixel_2"
        Me.opt_pixel_2.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_pixel_2.Size = New System.Drawing.Size(108, 27)
        Me.opt_pixel_2.TabIndex = 8
        Me.opt_pixel_2.TabStop = True
        Me.opt_pixel_2.Text = "Palette Color"
        '
        'opt_pixel_3
        '
        Me.opt_pixel_3.BackColor = System.Drawing.SystemColors.Control
        Me.opt_pixel_3.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_pixel_3.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_pixel_3.Location = New System.Drawing.Point(12, 94)
        Me.opt_pixel_3.Name = "opt_pixel_3"
        Me.opt_pixel_3.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_pixel_3.Size = New System.Drawing.Size(108, 27)
        Me.opt_pixel_3.TabIndex = 9
        Me.opt_pixel_3.TabStop = True
        Me.opt_pixel_3.Text = "RGB Color"
        '
        'Label2
        '
        Me.Label2.BackColor = System.Drawing.SystemColors.Control
        Me.Label2.Cursor = System.Windows.Forms.Cursors.Default
        Me.Label2.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Label2.Location = New System.Drawing.Point(112, 26)
        Me.Label2.Name = "Label2"
        Me.Label2.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Label2.Size = New System.Drawing.Size(48, 18)
        Me.Label2.TabIndex = 38
        Me.Label2.Text = "BitPixel"
        '
        'Frame1
        '
        Me.Frame1.BackColor = System.Drawing.SystemColors.Control
        Me.Frame1.Controls.Add(Me.Thumb_Check)
        Me.Frame1.Controls.Add(Me.Text_Dpi)
        Me.Frame1.Controls.Add(Me.opt_device_0)
        Me.Frame1.Controls.Add(Me.opt_device_1)
        Me.Frame1.Controls.Add(Me.Label4)
        Me.Frame1.Font = New System.Drawing.Font("Arial", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(128, Byte))
        Me.Frame1.ForeColor = System.Drawing.Color.Blue
        Me.Frame1.Location = New System.Drawing.Point(16, 96)
        Me.Frame1.Name = "Frame1"
        Me.Frame1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame1.Size = New System.Drawing.Size(217, 74)
        Me.Frame1.TabIndex = 0
        Me.Frame1.TabStop = False
        Me.Frame1.Text = "Device"
        '
        'Thumb_Check
        '
        Me.Thumb_Check.BackColor = System.Drawing.SystemColors.Control
        Me.Thumb_Check.Cursor = System.Windows.Forms.Cursors.Default
        Me.Thumb_Check.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Thumb_Check.Location = New System.Drawing.Point(124, 46)
        Me.Thumb_Check.Name = "Thumb_Check"
        Me.Thumb_Check.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Thumb_Check.Size = New System.Drawing.Size(89, 18)
        Me.Thumb_Check.TabIndex = 4
        Me.Thumb_Check.Text = "Thumbnail"
        '
        'Text_Dpi
        '
        Me.Text_Dpi.AcceptsReturn = True
        Me.Text_Dpi.AutoSize = False
        Me.Text_Dpi.BackColor = System.Drawing.SystemColors.Window
        Me.Text_Dpi.Cursor = System.Windows.Forms.Cursors.IBeam
        Me.Text_Dpi.ForeColor = System.Drawing.SystemColors.WindowText
        Me.Text_Dpi.Location = New System.Drawing.Point(168, 17)
        Me.Text_Dpi.MaxLength = 0
        Me.Text_Dpi.Name = "Text_Dpi"
        Me.Text_Dpi.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Text_Dpi.Size = New System.Drawing.Size(41, 20)
        Me.Text_Dpi.TabIndex = 2
        Me.Text_Dpi.Text = "72"
        Me.Text_Dpi.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
        '
        'opt_device_0
        '
        Me.opt_device_0.BackColor = System.Drawing.SystemColors.Control
        Me.opt_device_0.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_device_0.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_device_0.Location = New System.Drawing.Point(12, 17)
        Me.opt_device_0.Name = "opt_device_0"
        Me.opt_device_0.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_device_0.Size = New System.Drawing.Size(76, 23)
        Me.opt_device_0.TabIndex = 1
        Me.opt_device_0.TabStop = True
        Me.opt_device_0.Text = "Scanner"
        '
        'opt_device_1
        '
        Me.opt_device_1.BackColor = System.Drawing.SystemColors.Control
        Me.opt_device_1.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_device_1.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_device_1.Location = New System.Drawing.Point(12, 43)
        Me.opt_device_1.Name = "opt_device_1"
        Me.opt_device_1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_device_1.Size = New System.Drawing.Size(108, 23)
        Me.opt_device_1.TabIndex = 3
        Me.opt_device_1.TabStop = True
        Me.opt_device_1.Text = "Digital Camera"
        '
        'Label4
        '
        Me.Label4.BackColor = System.Drawing.SystemColors.Control
        Me.Label4.Cursor = System.Windows.Forms.Cursors.Default
        Me.Label4.ForeColor = System.Drawing.SystemColors.ControlText
        Me.Label4.Location = New System.Drawing.Point(96, 17)
        Me.Label4.Name = "Label4"
        Me.Label4.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Label4.Size = New System.Drawing.Size(65, 19)
        Me.Label4.TabIndex = 46
        Me.Label4.Text = "Resolution"
        '
        'Frame3
        '
        Me.Frame3.BackColor = System.Drawing.SystemColors.Control
        Me.Frame3.Controls.Add(Me.opt_size_0)
        Me.Frame3.Controls.Add(Me.opt_size_1)
        Me.Frame3.Controls.Add(Me.opt_size_2)
        Me.Frame3.Font = New System.Drawing.Font("Arial", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(128, Byte))
        Me.Frame3.ForeColor = System.Drawing.Color.Blue
        Me.Frame3.Location = New System.Drawing.Point(16, 320)
        Me.Frame3.Name = "Frame3"
        Me.Frame3.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.Frame3.Size = New System.Drawing.Size(84, 101)
        Me.Frame3.TabIndex = 11
        Me.Frame3.TabStop = False
        Me.Frame3.Text = "Paper Size"
        '
        'opt_size_0
        '
        Me.opt_size_0.BackColor = System.Drawing.SystemColors.Control
        Me.opt_size_0.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_size_0.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_size_0.Location = New System.Drawing.Point(12, 17)
        Me.opt_size_0.Name = "opt_size_0"
        Me.opt_size_0.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_size_0.Size = New System.Drawing.Size(52, 27)
        Me.opt_size_0.TabIndex = 12
        Me.opt_size_0.TabStop = True
        Me.opt_size_0.Text = "A4"
        '
        'opt_size_1
        '
        Me.opt_size_1.BackColor = System.Drawing.SystemColors.Control
        Me.opt_size_1.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_size_1.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_size_1.Location = New System.Drawing.Point(12, 43)
        Me.opt_size_1.Name = "opt_size_1"
        Me.opt_size_1.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_size_1.Size = New System.Drawing.Size(52, 27)
        Me.opt_size_1.TabIndex = 13
        Me.opt_size_1.TabStop = True
        Me.opt_size_1.Text = "B5"
        '
        'opt_size_2
        '
        Me.opt_size_2.BackColor = System.Drawing.SystemColors.Control
        Me.opt_size_2.Cursor = System.Windows.Forms.Cursors.Default
        Me.opt_size_2.ForeColor = System.Drawing.SystemColors.ControlText
        Me.opt_size_2.Location = New System.Drawing.Point(12, 69)
        Me.opt_size_2.Name = "opt_size_2"
        Me.opt_size_2.RightToLeft = System.Windows.Forms.RightToLeft.No
        Me.opt_size_2.Size = New System.Drawing.Size(52, 27)
        Me.opt_size_2.TabIndex = 14
        Me.opt_size_2.TabStop = True
        Me.opt_size_2.Text = "A5"
        '
        'ProgressBar1
        '
        Me.ProgressBar1.Location = New System.Drawing.Point(248, 568)
        Me.ProgressBar1.Name = "ProgressBar1"
        Me.ProgressBar1.Size = New System.Drawing.Size(192, 17)
        Me.ProgressBar1.TabIndex = 50
        '
        'MainMenu1
        '
        Me.MainMenu1.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.MenuItem1, Me.MenuItem3, Me.Menu_hanni, Me.MenuItem5, Me.MenuItem6, Me.MenuItem7})
        '
        'MenuItem1
        '
        Me.MenuItem1.Index = 0
        Me.MenuItem1.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_SelectSource, Me.MenuItem12, Me.Menu_OpenDS, Me.Menu_CloseDS, Me.MenuItem13, Me.Menu_Exec, Me.MenuItem14, Me.Menu_Exit})
        Me.MenuItem1.Text = "File(&F)"
        '
        'Menu_SelectSource
        '
        Me.Menu_SelectSource.Index = 0
        Me.Menu_SelectSource.Text = "Select TWAIN Source(&S)"
        '
        'MenuItem12
        '
        Me.MenuItem12.Index = 1
        Me.MenuItem12.Text = "-"
        '
        'Menu_OpenDS
        '
        Me.Menu_OpenDS.Index = 2
        Me.Menu_OpenDS.Text = "Open Data Source(&O)"
        '
        'Menu_CloseDS
        '
        Me.Menu_CloseDS.Index = 3
        Me.Menu_CloseDS.Text = "Close Data Source(&C)"
        '
        'MenuItem13
        '
        Me.MenuItem13.Index = 4
        Me.MenuItem13.Text = "-"
        '
        'Menu_Exec
        '
        Me.Menu_Exec.Index = 5
        Me.Menu_Exec.Text = "Execute(&E)"
        '
        'MenuItem14
        '
        Me.MenuItem14.Index = 6
        Me.MenuItem14.Text = "-"
        '
        'Menu_Exit
        '
        Me.Menu_Exit.Index = 7
        Me.Menu_Exit.Text = "Exit(&X)"
        '
        'MenuItem3
        '
        Me.MenuItem3.Index = 1
        Me.MenuItem3.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_Native, Me.Menu_Memory, Me.MenuItem18, Me.Menu_DisplayUI, Me.Menu_DisplayUI_C, Me.Menu_DisableUI})
        Me.MenuItem3.Text = "Settings(&S)"
        '
        'Menu_Native
        '
        Me.Menu_Native.Checked = True
        Me.Menu_Native.Index = 0
        Me.Menu_Native.Text = "Native Transfer"
        '
        'Menu_Memory
        '
        Me.Menu_Memory.Index = 1
        Me.Menu_Memory.Text = "memory Transfer"
        '
        'MenuItem18
        '
        Me.MenuItem18.Index = 2
        Me.MenuItem18.Text = "-"
        '
        'Menu_DisplayUI
        '
        Me.Menu_DisplayUI.Checked = True
        Me.Menu_DisplayUI.Index = 3
        Me.Menu_DisplayUI.Text = "Display UI"
        '
        'Menu_DisplayUI_C
        '
        Me.Menu_DisplayUI_C.Index = 4
        Me.Menu_DisplayUI_C.Text = "Display UI (Then Close)"
        '
        'Menu_DisableUI
        '
        Me.Menu_DisableUI.Index = 5
        Me.Menu_DisableUI.Text = "Suppress UI"
        '
        'Menu_hanni
        '
        Me.Menu_hanni.Index = 2
        Me.Menu_hanni.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_Brightness, Me.Menu_Contrast, Me.Menu_Gamma, Me.Menu_Highlight, Me.Menu_Shadow, Me.Menu_XRes, Me.Menu_YRes, Me.Menu_Threshold, Me.Menu_XScale, Me.Menu_YScale})
        Me.Menu_hanni.Text = "Range(&R)"
        '
        'Menu_Brightness
        '
        Me.Menu_Brightness.Index = 0
        Me.Menu_Brightness.Text = "Brightness($B)"
        '
        'Menu_Contrast
        '
        Me.Menu_Contrast.Index = 1
        Me.Menu_Contrast.Text = "Contrast(&C)"
        '
        'Menu_Gamma
        '
        Me.Menu_Gamma.Index = 2
        Me.Menu_Gamma.Text = "Gamma(&G)"
        '
        'Menu_Highlight
        '
        Me.Menu_Highlight.Index = 3
        Me.Menu_Highlight.Text = "Highlight(&H)"
        '
        'Menu_Shadow
        '
        Me.Menu_Shadow.Index = 4
        Me.Menu_Shadow.Text = "Shadow(&S)"
        '
        'Menu_XRes
        '
        Me.Menu_XRes.Index = 5
        Me.Menu_XRes.Text = "X Resolution(&X)"
        '
        'Menu_YRes
        '
        Me.Menu_YRes.Index = 6
        Me.Menu_YRes.Text = "Y Resolution(&Y)"
        '
        'Menu_Threshold
        '
        Me.Menu_Threshold.Index = 7
        Me.Menu_Threshold.Text = "Threshold(&T)"
        '
        'Menu_XScale
        '
        Me.Menu_XScale.Index = 8
        Me.Menu_XScale.Text = "Horizontal Scaling(&L)"
        '
        'Menu_YScale
        '
        Me.Menu_YScale.Index = 9
        Me.Menu_YScale.Text = "Vertical Scaling(&I)"
        '
        'MenuItem5
        '
        Me.MenuItem5.Index = 3
        Me.MenuItem5.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_Compression, Me.Menu_PixelType, Me.Menu_Unit, Me.Menu_Trans, Me.Menu_Orientation, Me.Menu_HalfTones, Me.Menu_Paper, Me.Menu_Bit, Me.Menu_BitDepthReduction})
        Me.MenuItem5.Text = "Enumerate(&E)"
        '
        'Menu_Compression
        '
        Me.Menu_Compression.Index = 0
        Me.Menu_Compression.Text = "Compression(&C)"
        '
        'Menu_PixelType
        '
        Me.Menu_PixelType.Index = 1
        Me.Menu_PixelType.Text = "Pixel Type(&P)"
        '
        'Menu_Unit
        '
        Me.Menu_Unit.Index = 2
        Me.Menu_Unit.Text = "Scan Units(&U)"
        '
        'Menu_Trans
        '
        Me.Menu_Trans.Index = 3
        Me.Menu_Trans.Text = "Transfer Method(&T)"
        '
        'Menu_Orientation
        '
        Me.Menu_Orientation.Index = 4
        Me.Menu_Orientation.Text = "Paper Orientation(&O)"
        '
        'Menu_HalfTones
        '
        Me.Menu_HalfTones.Index = 5
        Me.Menu_HalfTones.Text = "Halftone(&H)"
        '
        'Menu_Paper
        '
        Me.Menu_Paper.Index = 6
        Me.Menu_Paper.Text = "Paper Size(&S)"
        '
        'Menu_Bit
        '
        Me.Menu_Bit.Index = 7
        Me.Menu_Bit.Text = "Bitcount(&B)"
        '
        'Menu_BitDepthReduction
        '
        Me.Menu_BitDepthReduction.Index = 8
        Me.Menu_BitDepthReduction.Text = "Bit Depth Reduction(&R)"
        '
        'MenuItem6
        '
        Me.MenuItem6.Index = 4
        Me.MenuItem6.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_Feeder, Me.Menu_FeederLoad, Me.Menu_Indicator, Me.Menu_ControllUI, Me.Menu_Online, Me.Menu_Thumbnails, Me.Menu_Duplex, Me.Menu_ImageNum, Me.Menu_MaxSize, Me.Menu_MinSize})
        Me.MenuItem6.Text = "Query(&Q)"
        '
        'Menu_Feeder
        '
        Me.Menu_Feeder.Index = 0
        Me.Menu_Feeder.Text = "Feeder(&F)"
        '
        'Menu_FeederLoad
        '
        Me.Menu_FeederLoad.Index = 1
        Me.Menu_FeederLoad.Text = "Is Feeder Loaded?(&L)"
        '
        'Menu_Indicator
        '
        Me.Menu_Indicator.Index = 2
        Me.Menu_Indicator.Text = "Indicator(&I)"
        '
        'Menu_ControllUI
        '
        Me.Menu_ControllUI.Index = 3
        Me.Menu_ControllUI.Text = "UI Control(&U)"
        '
        'Menu_Online
        '
        Me.Menu_Online.Index = 4
        Me.Menu_Online.Text = "Power On/Off(&O)"
        '
        'Menu_Thumbnails
        '
        Me.Menu_Thumbnails.Index = 5
        Me.Menu_Thumbnails.Text = "Thumbnails(&T)"
        '
        'Menu_Duplex
        '
        Me.Menu_Duplex.Index = 6
        Me.Menu_Duplex.Text = "Duplex(&D)"
        '
        'Menu_ImageNum
        '
        Me.Menu_ImageNum.Index = 7
        Me.Menu_ImageNum.Text = "Picture Count(&P)"
        '
        'Menu_MaxSize
        '
        Me.Menu_MaxSize.Index = 8
        Me.Menu_MaxSize.Text = "Maximum Size(&X)"
        '
        'Menu_MinSize
        '
        Me.Menu_MinSize.Index = 9
        Me.Menu_MinSize.Text = "Minimum Size(&N)"
        '
        'MenuItem7
        '
        Me.MenuItem7.Index = 5
        Me.MenuItem7.MenuItems.AddRange(New System.Windows.Forms.MenuItem() {Me.Menu_Current, Me.Menu_ComboBoxt, Me.MenuItem52})
        Me.MenuItem7.Text = "Source Info(&I)"
        '
        'Menu_Current
        '
        Me.Menu_Current.Index = 0
        Me.Menu_Current.Text = "Current TWAIN Source(&C)"
        '
        'Menu_ComboBoxt
        '
        Me.Menu_ComboBoxt.Index = 1
        Me.Menu_ComboBoxt.Text = "Retrieved TWAIN Source(&S)"
        '
        'MenuItem52
        '
        Me.MenuItem52.Index = 2
        Me.MenuItem52.Text = ""
        '
        'TextBox1
        '
        Me.TextBox1.BackColor = System.Drawing.Color.FromArgb(CType(255, Byte), CType(255, Byte), CType(192, Byte))
        Me.TextBox1.ForeColor = System.Drawing.Color.FromArgb(CType(192, Byte), CType(0, Byte), CType(0, Byte))
        Me.TextBox1.Location = New System.Drawing.Point(8, 4)
        Me.TextBox1.Multiline = True
        Me.TextBox1.Name = "TextBox1"
        Me.TextBox1.Size = New System.Drawing.Size(468, 76)
        Me.TextBox1.TabIndex = 51
        Me.TextBox1.Text = "This scan sample program illustrates nearly all of the functionality of the Scan " & _
        "interface and is a useful program for testing scanners. If you are having proble" & _
        "ms with a scanner in your own application, please try testing it with this sampl" & _
        "e. If the scanner works here then you can be fairly certain that the problem wit" & _
        "h your scan code. If the scanner shows problems with this sample, please let us " & _
        "know."
        '
        'Form1
        '
        Me.AutoScaleBaseSize = New System.Drawing.Size(5, 13)
        Me.ClientSize = New System.Drawing.Size(486, 675)
        Me.Controls.Add(Me.TextBox1)
        Me.Controls.Add(Me.ProgressBar1)
        Me.Controls.Add(Me.Frame10)
        Me.Controls.Add(Me.Frame6)
        Me.Controls.Add(Me.Frame7)
        Me.Controls.Add(Me.Text_Contrast)
        Me.Controls.Add(Me.Frame5)
        Me.Controls.Add(Me.Frame9)
        Me.Controls.Add(Me.Frame4)
        Me.Controls.Add(Me.Frame2)
        Me.Controls.Add(Me.Frame1)
        Me.Controls.Add(Me.Frame3)
        Me.ForeColor = System.Drawing.SystemColors.WindowText
        Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog
        Me.Location = New System.Drawing.Point(311, 202)
        Me.Menu = Me.MainMenu1
        Me.Name = "Form1"
        Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
        Me.Text = "Scan Sample(COM)"
        Me.Frame10.ResumeLayout(False)
        Me.Frame6.ResumeLayout(False)
        Me.Frame7.ResumeLayout(False)
        Me.Frame5.ResumeLayout(False)
        Me.Frame9.ResumeLayout(False)
        CType(Me.ImageKit1, System.ComponentModel.ISupportInitialize).EndInit()
        Me.Frame4.ResumeLayout(False)
        Me.Frame2.ResumeLayout(False)
        Me.Frame1.ResumeLayout(False)
        Me.Frame3.ResumeLayout(False)
        Me.ResumeLayout(False)

    End Sub
#End Region
#Region "Upgrade Support "
    Private Shared m_vb6FormDefInstance As Form1
    Private Shared m_InitializingDefInstance As Boolean
    Public Shared Property DefInstance() As Form1
        Get
            If m_vb6FormDefInstance Is Nothing OrElse m_vb6FormDefInstance.IsDisposed Then
                m_InitializingDefInstance = True
                m_vb6FormDefInstance = New Form1
                m_InitializingDefInstance = False
            End If
            DefInstance = m_vb6FormDefInstance
        End Get
        Set(ByVal Value As Form1)
            m_vb6FormDefInstance = Value
        End Set
    End Property
#End Region

    Dim ScanStatus As Boolean

    Private Sub IsCapSupportBool(ByVal CapNo As Short, ByVal Title As String, ByVal Mes1 As String, ByVal Mes2 As String)
        Dim Ret As Boolean
        Dim Value As Integer

        ImageKit1.Scan.ScanDsName = Trim(Combo1.Text)

        Ret = ImageKit1.Scan.ScanIsCapSupported(CapNo, Value)
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.Scan.ErrorStatus), , "Error")
        Else
            If Value = 1 Then
                'MsgBox Title & " " & Mes1, , Title
                MsgBox(Mes1, , Title)
            Else
                'MsgBox Title & " " & Mes2, , Title
                MsgBox(Mes2, , Title)
            End If
        End If
    End Sub

    Private Sub job_init()
        opt_pixel_0.Checked = True
        opt_pixel_0_Click(opt_pixel_0, New System.EventArgs)

        opt_size_0.Checked = True
        opt_device_0.Checked = True
        opt_feed_0.Checked = True
        opt_unit_0.Checked = True
        opt_meter_0.Checked = True

        Text_Cnt.Text = ""
        Combo1.Text = "" 'Default Source
        ScanStatus = False
    End Sub

    Private Sub cmd_get_Click(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles cmd_get.Click
        Dim Ret As Boolean
        Dim DsList As String
        Dim DsName As String
        Dim DefDsName As String
        Dim i As Short
        Dim n As Short

        Cursor = System.Windows.Forms.Cursors.WaitCursor
        Ret = ImageKit1.Scan.List()
        Cursor = System.Windows.Forms.Cursors.Default

        DsList = ImageKit1.Scan.DsNameList
        If Ret = False Or Len(DsList) = 0 Then Exit Sub

        Combo1.Items.Clear()
        'default Scanner (the default scanner is the scanner listed before the first comma)
        i = InStr(DsList, ",")
        If i <= 1 Then
            DefDsName = ""
        Else
            DefDsName = VB.Left(DsList, i - 1)
            DsList = Mid(DsList, i + 1)
        End If

        'scan device list
        n = 0
        Do While True
            i = InStr(DsList, ",")
            If i <= 1 Then Exit Do
            DsName = VB.Left(DsList, i - 1)
            DsList = Mid(DsList, i + 1)
            VB6.SetItemString(Combo1, n, DsName)
            n = n + 1
        Loop

        Combo1.Text = DefDsName 'default scanner
        ImageKit1.Scan.DsName = Trim(Combo1.Text)
    End Sub

    Private Sub Form1_Load(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles MyBase.Load
        Dim Ret As Boolean

        Ret = ImageKit1.Scan.Initialize(Handle.ToInt32, 1, 0, "ImageKit7 Sample", "NEWTONE Corp.", "ImageKit", "ImageKit7")

        job_init()
    End Sub

    Private Sub Form1_Closed(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles MyBase.Closed
        Dim Ret As Boolean

        Ret = ImageKit1.Scan.Terminate()
    End Sub

    Private Sub GetCapRange(ByVal CapNo As Short, ByVal Title As String)
        Dim Ret As Boolean
        Dim Mes As String
        Dim ConType As Short

        ImageKit1.Scan.DsName = Trim(Combo1.Text)
        Ret = ImageKit1.Scan.GetCapRange(CapNo, ConType)
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
        Else
            If ConType = 4 Then
                GetCapEnum(CapNo, CInt(ImageKit1.Scan.RangeMax), Title)
            Else
                Mes = "ConType = " & CStr(ConType) & Chr(13) & Chr(10)
                Mes = Mes & "Min = " & CStr(ImageKit1.Scan.RangeMin) & Chr(13) & Chr(10)
                Mes = Mes & "Max = " & CStr(ImageKit1.Scan.RangeMax) & Chr(13) & Chr(10)
                Mes = Mes & "StepSize = " & CStr(ImageKit1.Scan.RangeStep) & Chr(13) & Chr(10)
                Mes = Mes & "Default = " & CStr(ImageKit1.Scan.RangeDefault) & Chr(13) & Chr(10)
                Mes = Mes & "Current = " & CStr(ImageKit1.Scan.RangeCurrent)
                MsgBox(Mes, , Title)
            End If
        End If
    End Sub

    Private Sub GetCapEnum(ByVal CapNo As Short, ByVal Cnt As Integer, ByVal Title As String)
        Dim Num As Integer
        Dim i As Integer
        Dim Mes As String
        Dim Ilist() As Short
        Dim Slist() As Single
        Dim Chk As Integer
        Dim ConType As Short
        Dim CurrentIndex As Integer
        Dim DefaultIndex As Integer

        ImageKit1.Scan.DsName = Trim(Combo1.Text)

        If CapNo = 0 Then 'bitcount
            ReDim Ilist(Cnt)

            If (opt_pixel_0.Checked = True) Then
                i = 0
            ElseIf (opt_pixel_1.Checked = True) Then
                i = 1
            ElseIf (opt_pixel_2.Checked = True) Then
                i = 2
            Else
                i = 3
            End If

            Select Case i
                Case 0
                    ImageKit1.Scan.PixelType = IMAGEKIT7Lib.ScanPixelTypeConstants.ikScanPixelBW
                    Title = Title & "(Black and White)"
                Case 1
                    ImageKit1.Scan.PixelType = IMAGEKIT7Lib.ScanPixelTypeConstants.ikScanPixelGray
                    Title = Title & "(Grayscale)"
                Case 2
                    ImageKit1.Scan.PixelType = IMAGEKIT7Lib.ScanPixelTypeConstants.ikScanPixelPalette
                    Title = Title & "(Palette color)"
                Case 3
                    ImageKit1.Scan.PixelType = IMAGEKIT7Lib.ScanPixelTypeConstants.ikScanPixelRGB
                    Title = Title & "(RGB color)"
            End Select
            Num = ImageKit1.Scan.GetBitDepth(Ilist(0), Cnt)
            If Num = 0 Then
                MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
            Else
                Mes = ""
                If Cnt > Num Then
                    Chk = Num
                Else
                    Chk = Cnt
                End If
                For i = 0 To Chk - 1
                    If Ilist(i) <> 0 Then
                        Mes = Mes & CStr(Ilist(i)) & Chr(13) & Chr(10)
                    End If
                Next i
                MsgBox(Mes, , Title)
            End If
        Else
            ReDim Slist(Cnt)
            Num = ImageKit1.Scan.GetCapEnum(CapNo, ConType, Slist(0), CurrentIndex, DefaultIndex, Cnt)
            If Num = 0 Then
                MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
            Else
                Mes = ""
                If Cnt > Num Then
                    Chk = Num
                Else
                    Chk = Cnt
                End If

                If Chk > 30 Then
                    MsgBox("The number of elements exceeds 30")
                Else
                    Mes = "ConType = " & CStr(ConType) & Chr(13) & Chr(10)
                    If Chk - 1 >= CurrentIndex Then
                        Mes = Mes & "Current Value = " & CStr(Slist(CurrentIndex)) & Chr(13) & Chr(10)
                    End If
                    If Chk - 1 >= DefaultIndex Then
                        Mes = Mes & "Default Value = " & CStr(Slist(DefaultIndex)) & Chr(13) & Chr(10)
                    End If
                    For i = 0 To Chk - 1
                        Mes = Mes & CStr(Slist(i)) & Chr(13) & Chr(10)
                    Next i
                    MsgBox(Mes, , Title)
                End If
            End If
        End If
    End Sub

    Private Sub Disp_DataSource(ByVal Title As String)
        Dim Mes As String

        Mes = "Protocol Version = " & CStr(ImageKit1.Scan.ProtocolMajor) & "." & CStr(ImageKit1.Scan.ProtocolMinor) & Chr(13) & Chr(10)
        Mes = Mes & "Manufacturer Name = " & ImageKit1.Scan.Manufacturer & Chr(13) & Chr(10)
        Mes = Mes & "Product Family = " & ImageKit1.Scan.ProductFamily & Chr(13) & Chr(10)
        Mes = Mes & "Product Name = " & ImageKit1.Scan.ProductName & Chr(13) & Chr(10)
        Mes = Mes & "Version = " & CStr(ImageKit1.Scan.SourceMajor) & "." & CStr(ImageKit1.Scan.SourceMinor) & Chr(13) & Chr(10)
        Mes = Mes & "Source Information = " & ImageKit1.Scan.SourceVersionInfo
        MsgBox(Mes, , Title)
    End Sub


    Private Sub ImageKit1_AfterScan(ByVal sender As Object, ByVal e As AxIMAGEKIT7Lib._IImageKitEvents_AfterScanEvent) Handles ImageKit1.AfterScan
        Text_Cnt.Text = CStr(e.imageCount)
        ImageKit1.ImageHandle = ImageKit1.CopyImage(e.dibHandle)

        ImageKit1.Display(IMAGEKIT7Lib.DispModeConstants.ikScale)
    End Sub

    'SelectSource
    Private Sub Menu_SelectSource_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_SelectSource.Click
        Dim Ret As Boolean
        Ret = ImageKit1.Scan.Select()
    End Sub

    'open data source
    Private Sub Menu_OpenDS_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_OpenDS.Click
        Dim Ret As Boolean

        ImageKit1.Scan.DsName = Trim(Combo1.Text)
        Ret = ImageKit1.Scan.OpenDS()
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
        End If
    End Sub

    'current TWAIN source
    Private Sub Menu_Current_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Current.Click
        Dim Ret As Boolean

        ImageKit1.Scan.DsName = ""
        Ret = ImageKit1.Scan.GetDSInfo()
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
        Else
            Disp_DataSource("Currently selected source")
        End If
    End Sub

    'close data source
    Private Sub Menu_CloseDS_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_CloseDS.Click
        Dim Ret As Boolean

        Ret = ImageKit1.Scan.CloseDS()
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
        End If
    End Sub

    'execute
    Private Sub Menu_Exec_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Exec.Click
        Dim Ret, OpenFlg As Boolean
        Dim i As Short
        Dim pixel As Short
        Dim sizeno As Short
        Dim Index(10) As Integer
        Dim Num As Long, CurrentIndex As Long, DefaultIndex As Long
        Dim ConType As Integer

        OpenFlg = False

        On Error GoTo err01

        'clear
        Text_Cnt.Text = ""

        If Menu_DisplayUI.Checked = True Then
            ImageKit1.Scan.UiMode = IMAGEKIT7Lib.ScanUIModeConstants.ikScanUI 'DisplayUI
        ElseIf Menu_DisplayUI_C.Checked = True Then
            ImageKit1.Scan.UiMode = IMAGEKIT7Lib.ScanUIModeConstants.ikScanUICLOSE 'DisplayUI(Close)
        Else
            ImageKit1.Scan.UiMode = IMAGEKIT7Lib.ScanUIModeConstants.ikScanNONUI 'DisableUI
        End If

        If Menu_Native.Checked = True Then
            ImageKit1.Scan.TransferMode = IMAGEKIT7Lib.ScanTransferConstants.ikScanNative
        Else
            ImageKit1.Scan.TransferMode = IMAGEKIT7Lib.ScanTransferConstants.ikScanMemory
        End If
        ImageKit1.Scan.Compression = 0

        ImageKit1.Scan.DsName = Trim(Combo1.Text)

        If ImageKit1.Scan.UiMode = IMAGEKIT7Lib.ScanUIModeConstants.ikScanNONUI Then
            If ImageKit1.Scan.IsOpenDS = False Then
                OpenFlg = True
                ImageKit1.Scan.OpenDS()
            End If

            'paper size
            Dim Slist(2) As Single
            Num = ImageKit1.Scan.GetCapEnum(&H1122, ConType, Slist(0), CurrentIndex, DefaultIndex, 0)

            If (opt_pixel_0.Checked = True) Then
                pixel = 0
            ElseIf (opt_pixel_1.Checked = True) Then
                pixel = 1
            ElseIf (opt_pixel_2.Checked = True) Then
                pixel = 2
            ElseIf (opt_pixel_3.Checked = True) Then
                pixel = 3
            End If

            Select Case pixel
                Case 0
                    ImageKit1.Scan.PixelType = IMAGEKIT7Lib.ScanPixelTypeConstants.ikScanPixelBW
                    ImageKit1.Scan.BitDepth = 1
                Case 1
                    ImageKit1.Scan.PixelType = IMAGEKIT7Lib.ScanPixelTypeConstants.ikScanPixelGray
                    ImageKit1.Scan.BitDepth = 8
                Case 2
                    ImageKit1.Scan.PixelType = IMAGEKIT7Lib.ScanPixelTypeConstants.ikScanPixelPalette
                    ImageKit1.Scan.BitDepth = 8
                Case 3
                    ImageKit1.Scan.PixelType = IMAGEKIT7Lib.ScanPixelTypeConstants.ikScanPixelRGB
                    ImageKit1.Scan.BitDepth = 24
            End Select

            ImageKit1.Scan.RectLeft = 0
            ImageKit1.Scan.RectTop = 0
            If (opt_size_0.Checked = True) Then
                sizeno = 0
            ElseIf (opt_size_1.Checked = True) Then
                sizeno = 1
            ElseIf (opt_size_2.Checked = True) Then
                sizeno = 2
            End If


            '-----device
            If opt_device_0.Checked = True Then
                ImageKit1.Scan.XResolution = Val(Text_Dpi.Text)
                ImageKit1.Scan.YResolution = Val(Text_Dpi.Text)

                If opt_feed_0.Checked = True Then
                    ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanDOC
                ElseIf opt_feed_1.Checked = True Then
                    ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanADF1
                ElseIf opt_feed_2.Checked = True Then
                    ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanADF2
                End If
            Else
                ImageKit1.Scan.XResolution = 0
                ImageKit1.Scan.YResolution = 0
                If Thumb_Check.CheckState = 1 Then
                    ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanCAMThumb
                Else
                    ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanCAM
                End If
            End If

            If opt_unit_0.Checked = True Then
                'inch
                Select Case sizeno
                    Case 0
                        ImageKit1.Scan.RectBottom = 2970 / 100 / 2.54
                        ImageKit1.Scan.RectRight = 2100 / 100 / 2.54
                    Case 1
                        ImageKit1.Scan.RectBottom = 2570 / 100 / 2.54
                        ImageKit1.Scan.RectRight = 1820 / 100 / 2.54
                    Case 2
                        ImageKit1.Scan.RectBottom = 2100 / 100 / 2.54
                        ImageKit1.Scan.RectRight = 1480 / 100 / 2.54
                End Select
                ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanInch
            ElseIf opt_unit_1.Checked = True Then
                'cm
                Select Case sizeno
                    Case 0
                        ImageKit1.Scan.RectBottom = 29.7
                        ImageKit1.Scan.RectRight = 21
                    Case 1
                        ImageKit1.Scan.RectBottom = 25.7
                        ImageKit1.Scan.RectRight = 18.2
                    Case 2
                        ImageKit1.Scan.RectBottom = 21
                        ImageKit1.Scan.RectRight = 14.8
                End Select
                ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanCM
            Else
                'pixel
                Select Case sizeno
                    Case 0
                        ImageKit1.Scan.RectBottom = ImageKit1.Scan.XResolution * (2970 / 100 / 2.54)
                        ImageKit1.Scan.RectRight = ImageKit1.Scan.XResolution * (2100 / 100 / 2.54)
                    Case 1
                        ImageKit1.Scan.RectBottom = ImageKit1.Scan.XResolution * (2570 / 100 / 2.54)
                        ImageKit1.Scan.RectRight = ImageKit1.Scan.XResolution * (1820 / 100 / 2.54)
                    Case 2
                        ImageKit1.Scan.RectBottom = ImageKit1.Scan.XResolution * (2100 / 100 / 2.54)
                        ImageKit1.Scan.RectRight = ImageKit1.Scan.XResolution * (1480 / 100 / 2.54)
                End Select
                ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanPixel
            End If

            If Unit_Check.CheckState = 1 Then
                ImageKit1.Scan.UnitFlag = 1
            Else
                ImageKit1.Scan.UnitFlag = 0
            End If

            ImageKit1.Scan.XScaling = 1.0#
            ImageKit1.Scan.YScaling = 1.0#
            ImageKit1.Scan.Contrast = Val(Text_Contrast.Text)
            ImageKit1.Scan.Threshold = Val(Text_Thres.Text)
            ImageKit1.Scan.Brightness = Val(Text_Bright.Text)
            ImageKit1.Scan.BitDepth = Val(Text_Bit.Text)
            ImageKit1.Scan.Gamma = Val(Text_Gamma.Text)
            ImageKit1.Scan.Highlight = Val(Text_Highlight.Text)
            ImageKit1.Scan.Shadow = Val(Text_shadow.Text)

            If opt_meter_0.Checked = True Then
                ImageKit1.Scan.Indicator = False
            ElseIf opt_meter_1.Checked = True Then
                ImageKit1.Scan.Indicator = True
            End If

            ImageKit1.Scan.PageCount = -1
            ImageKit1.Scan.Orientation = IMAGEKIT7Lib.ScanOrientationConstants.ikScanRotate0
            If Num = 0 Then
                ImageKit1.Scan.PaperSize = 0
            End If
            ImageKit1.Scan.BitDepthReduction = 0
            ImageKit1.Scan.HalfTone = ""

        End If

        ScanStatus = True 'Scan Start
        Cursor = System.Windows.Forms.Cursors.WaitCursor
        Ret = ImageKit1.Scan.Exec(Index(0))
        Cursor = System.Windows.Forms.Cursors.Default
        ScanStatus = False 'Scan End

        If Ret = False Then
            Beep()
            MsgBox("Could not scan image, ErrNo = " & CStr(ImageKit1.Scan.ErrorStatus))
            Exit Sub
        End If

        If OpenFlg Then
            ImageKit1.Scan.CloseDS()
        End If

        Exit Sub

err01:
        If Err.Number < 0 Then
            Resume Next
        End If
        If Err.Number = 7 Then
            Beep()
            MsgBox("Not enough memory")
        Else
            Beep()
            MsgBox("(" & CStr(Err.Number) & ")" & ErrorToString(Err.Number))
        End If
        System.Windows.Forms.Application.DoEvents()

        If OpenFlg Then
            ImageKit1.Scan.CloseDS()
        End If

        Exit Sub
    End Sub

    Private Sub Menu_Exit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Exit.Click
        Me.Close()
    End Sub

    'native transfer
    Private Sub Menu_Native_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Native.Click
        If Menu_Native.Checked = False Then
            Menu_Native.Checked = True
            Menu_Memory.Checked = False
        End If
    End Sub

    'memory transfer
    Private Sub Menu_Memory_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Memory.Click
        If Menu_Memory.Checked = False Then
            Menu_Native.Checked = False
            Menu_Memory.Checked = True
        End If
    End Sub

    'display UI
    Private Sub Menu_DisplayUI_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_DisplayUI.Click
        If Menu_DisplayUI.Checked = True Then Exit Sub

        Menu_DisplayUI.Checked = True
        Menu_DisplayUI_C.Checked = False
        Menu_DisableUI.Checked = False
    End Sub

    'display UI(then close)
    Private Sub Menu_DisplayUI_C_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_DisplayUI_C.Click
        If Menu_DisplayUI_C.Checked = True Then Exit Sub

        Menu_DisplayUI.Checked = False
        Menu_DisplayUI_C.Checked = True
        Menu_DisableUI.Checked = False
    End Sub

    'suppress UI
    Private Sub Menu_DisableUI_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_DisableUI.Click
        If Menu_DisableUI.Checked = True Then Exit Sub

        Menu_DisplayUI.Checked = False
        Menu_DisplayUI_C.Checked = False
        Menu_DisableUI.Checked = True
    End Sub

    'brightness
    Private Sub Menu_Brightness_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Brightness.Click
        GetCapRange(&H1101S, "Brightness")
    End Sub

    'contrast
    Private Sub Menu_Contrast_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Contrast.Click
        GetCapRange(&H1103S, "Contrast")
    End Sub

    'gamma
    Private Sub Menu_Gamma_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Gamma.Click
        GetCapRange(&H1108S, "Gamma")
    End Sub

    'highlight
    Private Sub Menu_Highlight_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Highlight.Click
        GetCapRange(&H110AS, "Highlight")
    End Sub

    'shadow
    Private Sub Menu_Shadow_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Shadow.Click
        GetCapRange(&H1113S, "Shadow")
    End Sub
    'X Resolution
    Private Sub Menu_XRes_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_XRes.Click
        GetCapRange(&H1118S, "Horizontal resolution")
    End Sub

    'Y resolution
    Private Sub Menu_YRes_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_YRes.Click
        GetCapRange(&H1119S, "Vertical resolution")
    End Sub

    'threshold
    Private Sub Menu_Threshold_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Threshold.Click
        GetCapRange(&H1123S, "Threshold")
    End Sub

    'horizontal scaling
    Private Sub Menu_XScale_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_XScale.Click
        GetCapRange(&H1124S, "Horizontal scaling")
    End Sub

    'vertical scaling
    Private Sub Menu_YScale_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Menu_YScale.Click
        GetCapRange(&H1125S, "Vertical scaling")
    End Sub

    'compression
    Private Sub Menu_Compression_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Compression.Click
        GetCapEnum(&H100S, 13, "Compression method")
    End Sub

    'pixel type
    Private Sub Menu_PixelType_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_PixelType.Click
        GetCapEnum(&H101S, 9, "Pixel type")
    End Sub

    'scan units
    Private Sub Menu_Unit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Unit.Click
        GetCapEnum(&H102S, 6, "Scan units")
    End Sub

    'transfer method
    Private Sub Menu_Trans_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Trans.Click
        GetCapEnum(&H103S, 4, "Transfer method")
    End Sub

    'paper orientation
    Private Sub Menu_Orientation_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Orientation.Click
        GetCapEnum(&H1110S, 4, "Orientation")
    End Sub

    'paper size
    Private Sub Menu_Paper_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Paper.Click
        GetCapEnum(&H1122S, 20, "Paper size")
    End Sub

    'halftone
    Private Sub Menu_HalfTones_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_HalfTones.Click
        Dim Num As Integer
        Dim i, n As Integer
        Dim Mes As String
        Dim Slist As Single
        Dim Chk As Integer
        Dim ConType As Short
        Dim CurrentIndex As Integer
        Dim DefaultIndex As Integer
        Dim StrList As String
        Dim Work() As String

        ImageKit1.Scan.DsName = Trim(Combo1.Text)
        Num = ImageKit1.Scan.GetCapEnum(&H1109S, ConType, Slist, CurrentIndex, DefaultIndex, 0)
        If Num = 0 Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
            Exit Sub
        End If

        StrList = ImageKit1.Scan.HalfToneList

        ReDim Work(Num)
        Mes = "ConType = " & CStr(ConType) & Chr(13) & Chr(10)

        n = 0
        Do While True
            i = InStr(StrList, ",")
            If i <= 1 Then Exit Do
            Work(n) = VB.Left(StrList, i - 1)
            StrList = Mid(StrList, i + 1)
            n = n + 1
        Loop

        Mes = Mes & "Current = " & Work(CurrentIndex) & Chr(13) & Chr(10)
        Mes = Mes & "Default = " & Work(DefaultIndex) & Chr(13) & Chr(10)
        For i = 0 To Num - 1
            Mes = Mes & Work(i) & Chr(13) & Chr(10)
        Next i
        MsgBox(Mes, , "Halftone")
    End Sub

    'bitcount
    Private Sub Menu_Bit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Bit.Click
        GetCapEnum(0, 10, "Bitcount")
    End Sub

    'Bit Depth Reduction
    Private Sub Menu_BitDepthReduction_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_BitDepthReduction.Click
        GetCapEnum(&H112CS, 4, "Changing color depth")
    End Sub

    'feeder
    Private Sub Menu_Feeder_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Feeder.Click
        IsCapSupportBool(&H1002S, "Use the feeder?", "Yes", "No")
    End Sub

    'Is Feeder Loaded?
    Private Sub Menu_FeederLoad_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_FeederLoad.Click
        IsCapSupportBool(&H1003S, "Is there paper in the feeder?", "Yes", "No")
    End Sub

    'indicator
    Private Sub Menu_Indicator_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Indicator.Click
        IsCapSupportBool(&H100BS, "Indicator", "OK", "NG")
    End Sub

    'UI control
    Private Sub Menu_ControllUI_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_ControllUI.Click
        IsCapSupportBool(&H100ES, "UI Control", "OK", "NG")
    End Sub

    'power ON/OFF
    Private Sub Menu_Online_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Online.Click
        IsCapSupportBool(&H100FS, "Power switch", "ON", "OFF")
    End Sub

    'thumbnail
    Private Sub Menu_Thumbnails_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Thumbnails.Click
        IsCapSupportBool(&H1011S, "Thumbnail", "OK", "NG")
    End Sub

    'duplex
    Private Sub Menu_Duplex_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_Duplex.Click
        Dim Ret As Boolean
        Dim Value As Integer

        ImageKit1.Scan.DsName = Trim(Combo1.Text)
        Ret = ImageKit1.Scan.IsCapSupported(&H1012S, Value)
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
        Else
            Select Case Value
                Case 0
                    MsgBox("Unsupported", , "Duplex")
                Case 1
                    MsgBox("1 PASS", , "Duplex")
                Case 2
                    MsgBox("2 PASS", , "Duplex")
            End Select
        End If
    End Sub

    'image number
    Private Sub Menu_ImageNum_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_ImageNum.Click
        Dim Ret As Boolean
        Dim Value As Integer

        ImageKit1.Scan.DsName = Trim(Combo1.Text)
        Ret = ImageKit1.Scan.IsCapSupported(&H112ES, Value)
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
        Else
            MsgBox(CStr(Value), , "Number of images")
        End If
    End Sub

    'maximum size
    Private Sub Menu_MaxSize_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_MaxSize.Click
        Dim Ret As Boolean
        Dim mWidth As Single
        Dim mHeight As Single
        Dim Mes As String

        If opt_unit_0.Checked = True Then
            ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanInch
        ElseIf opt_unit_1.Checked = True Then
            ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanCM
        Else
            ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanPixel
        End If

        If opt_feed_0.Checked = True Then
            ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanDOC
        ElseIf opt_feed_1.Checked = True Then
            ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanADF1
        ElseIf opt_feed_2.Checked = True Then
            ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanADF2
        End If

        ImageKit1.Scan.DsName = Trim(Combo1.Text)
        Ret = ImageKit1.Scan.GetPhysicalSize(mWidth, mHeight)
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error(Maximum size)")
        Else
            Mes = "Width = " & CStr(mWidth) & ", Height = " & CStr(mHeight)
            MsgBox(Mes, , "Maximum scanning area")
        End If
    End Sub

    'minimum size
    Private Sub Menu_MinSize_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_MinSize.Click
        Dim Ret As Boolean
        Dim mWidth As Single
        Dim mHeight As Single
        Dim Mes As String

        If opt_unit_0.Checked = True Then
            ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanInch
        ElseIf opt_unit_1.Checked = True Then
            ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanCM
        Else
            ImageKit1.Scan.UnitMode = IMAGEKIT7Lib.ScanUnitConstants.ikScanPixel
        End If

        If opt_feed_0.Checked = True Then
            ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanDOC
        ElseIf opt_feed_1.Checked = True Then
            ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanADF1
        ElseIf opt_feed_2.Checked = True Then
            ImageKit1.Scan.ScanMode = IMAGEKIT7Lib.ScanModeConstants.ikScanADF2
        End If

        ImageKit1.Scan.DsName = Trim(Combo1.Text)
        Ret = ImageKit1.Scan.GetMinimumSize(mWidth, mHeight)
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error(Smallest size)")
        Else
            Mes = "Width = " & CStr(mWidth) & ", Height = " & CStr(mHeight)
            MsgBox(Mes, , "Smallest scanning area")
        End If
    End Sub

    'Retrieved TWAIN Source
    Private Sub Menu_ComboBoxt_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Menu_ComboBoxt.Click
        Dim Ret As Boolean

        ImageKit1.Scan.DsName = Trim(Combo1.Text)
        Ret = ImageKit1.Scan.GetDSInfo()
        If Ret = False Then
            MsgBox("Error No = " & CStr(ImageKit1.ErrorStatus), , "Error")
        Else
            Disp_DataSource("TWAIN source")
        End If
    End Sub

    Private Sub opt_pixel_0_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles opt_pixel_0.Click
        Text_Thres.Enabled = True 'threshold
        Text_Contrast.Enabled = False
        Text_Bright.Enabled = False
        Text_Gamma.Enabled = False
        Text_Highlight.Enabled = False
        Text_shadow.Enabled = False

        Text_Bit.Text = "1"

    End Sub

    Private Sub opt_pixel_1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles opt_pixel_1.Click
        Text_Contrast.Enabled = True
        Text_Thres.Enabled = False 'threshold
        Text_Bright.Enabled = True
        Text_Gamma.Enabled = True
        Text_Highlight.Enabled = True
        Text_shadow.Enabled = True

        Text_Bit.Text = "8"
    End Sub

    Private Sub opt_pixel_2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles opt_pixel_2.Click
        Text_Contrast.Enabled = True
        Text_Thres.Enabled = False 'threshold’l
        Text_Bright.Enabled = True
        Text_Gamma.Enabled = True
        Text_Highlight.Enabled = True
        Text_shadow.Enabled = True

        Text_Bit.Text = "8"
    End Sub

    Private Sub opt_pixel_3_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles opt_pixel_3.Click
        Text_Contrast.Enabled = True
        Text_Thres.Enabled = False 'threshold
        Text_Bright.Enabled = True
        Text_Gamma.Enabled = True
        Text_Highlight.Enabled = True
        Text_shadow.Enabled = True

        Text_Bit.Text = "24"
    End Sub

    Private Sub opt_device_0_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles opt_device_0.Click
        Label4.Enabled = True
        Text_Dpi.Enabled = True
        Thumb_Check.Enabled = False
    End Sub

    Private Sub opt_device_1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles opt_device_1.Click
        Label4.Enabled = False
        Text_Dpi.Enabled = False
        Thumb_Check.Enabled = True
    End Sub

    Public Overrides Property Anchor() As System.Windows.Forms.AnchorStyles
        Get

        End Get
        Set(ByVal Value As System.Windows.Forms.AnchorStyles)

        End Set
    End Property

    Protected Overrides Function GetService(ByVal service As System.Type) As Object

    End Function
End Class