This project has moved. For the latest updates, please go here.

Not fire _twain_AcquireCompleted event

May 27, 2016 at 3:21 PM
Hello Saraff Very nice library, very very useful for everyone.

My question is i wrote this lines...

this._twain.OpenDataSource();
_twain.Capabilities.FeederEnabled.Set(true);
_twain.Capabilities.AutoFeed.Set(true);
_twain.Capabilities.XferCount.Set(5);
_twain.DisableAfterAcquire = false;
this._twain.Acquire();

than and than only AcquiredCompleted event is fired
And if i remove no of XferCount than after scanning all pages system will on a wait mode not fire a completed event.

So please give me any solution for this.
I don't want give no of pages may be it will 50 or more, i need when my all pages(Which is put of a tray) scan after that system fires Completed event.

Please help for this.

Thank you in advance.
Coordinator
May 27, 2016 at 5:48 PM
Hello, VishalJani.
Try remove line:
_twain.DisableAfterAcquire = false; 
or write follow:
_twain.DisableAfterAcquire = true; 
Marked as answer by VishalJani on 5/30/2016 at 3:09 AM
May 30, 2016 at 10:00 AM
Thank you for your Reply once again.

That solution work for me, But one more thing i don't want to give no of pages count...

_twain.Capabilities.XferCount.Set(5);

When i comment that line than completed event is not fired.

Please help for this.

Thank you.
Coordinator
May 30, 2016 at 5:27 PM
Hello, VishalJani.
The fact that you turn on the Automatic Document Feeder. By default the XferCount is equal to infinity. Therefore, the only way for the scanner to report the end of the scan - this is to inform you that a user canceled the scanning (in a Twain32.AcquireError instead a Twain32.AcquiredCompleted).
Try process AcquireError event.