My VB6 program has a problem when try to acquire the image from ImgxTwain second time after user select cancel the first time. For the first time it works fine and if user select to scan it also works fine second time.
However, if user click cancel from the scan dialog instead of click scan then the second time the scan dialog box will not show up. It just run thru the code without any error but does not show the scan dialog box neither.
My ImgX that I am using is version 6.4 and here is the code. Can someone help please. Thanks a lot.
Private WithEvents m_ImgX_Twain As ImgXTwain
Private Sub Command1_Click()
m_ImgX_Twain.Acquire False, Me.hWnd
Private Sub Form_Load()
Set m_ImgX_Twain = New ImgXTwain
Private Sub Form_Unload(Cancel As Integer)
Set m_ImgX_Twain = Nothing
Private Sub m_ImgX_Twain_AcquireCanceled()
Private Sub m_ImgX_Twain_AcquireFinished()
MsgBox "Image Acquire Finished"
Private Sub m_ImgX_Twain_CanCloseTwain()
MsgBox "Cancel Close Twain"
Private Sub m_ImgX_Twain_ImageAcquired(Image As ImgX6.ImgX_Image)
MsgBox "Image Acquired"
Private Sub m_ImgX_Twain_TwainError(ByVal erNum As Long, ByVal erSource As String, ByVal Description As String)
MsgBox "Twain Error"