EzTwain Freeware

For everything that's not in any way related to PureBasic. General chat etc...
infratec
Always Here
Always Here
Posts: 7662
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: EzTwain Freeware

Post by infratec »

Added SelectSourceByName(), GetAcquiredImage(), SetTwainMode()

GetAcquiredImage() returns a hDIB, there is a procedure here in the forum which shows how to get the image from that handle.

I don't know why AcquireToClipboard() is not working.

The help file is very complete.
Last edited by infratec on Sat May 06, 2023 9:26 am, edited 1 time in total.
User avatar
Kwai chang caine
Always Here
Always Here
Posts: 5499
Joined: Sun Nov 05, 2006 11:42 pm
Location: Lyon - France

Re: EzTwain Freeware

Post by Kwai chang caine »

Worst..i have even an IMA on line on your new code

Code: Select all

SysDestroy()
Thanks INFRATEC, i take a look to all this splendid library 8)
ImageThe happiness is a road...
Not a destination
infratec
Always Here
Always Here
Posts: 7662
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: EzTwain Freeware

Post by infratec »

Hm ... I need a scanner :oops:

Btw. DTWAIN_BMP was right, I added the missing constants.
User avatar
Kwai chang caine
Always Here
Always Here
Posts: 5499
Joined: Sun Nov 05, 2006 11:42 pm
Location: Lyon - France

Re: EzTwain Freeware

Post by Kwai chang caine »

Master wrote:Hm ... I need a scanner :oops:
I exchange my old scanner for your great knowledge :mrgreen: :idea:

Here works : AcquireFile and AcquireNative 8)
But always IMA with AcquireToClipboard :|
ImageThe happiness is a road...
Not a destination
infratec
Always Here
Always Here
Posts: 7662
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: EzTwain Freeware

Post by infratec »

Enabled Logging,
infratec
Always Here
Always Here
Posts: 7662
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: EzTwain Freeware

Post by infratec »

Please try to use PrototypeC for the AcquireToClipboard function.
User avatar
Kwai chang caine
Always Here
Always Here
Posts: 5499
Joined: Sun Nov 05, 2006 11:42 pm
Location: Lyon - France

Re: EzTwain Freeware

Post by Kwai chang caine »

Enabled Logging, :shock:
PrototypeC :cry:
:oops:
ImageThe happiness is a road...
Not a destination
infratec
Always Here
Always Here
Posts: 7662
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: EzTwain Freeware

Post by infratec »

I made a fault, try:

Code: Select all

DTWAIN::AcquireToClipboard(Source, DTWAIN::#DTWAIN_PT_DEFAULT, 1, DTWAIN::#DTWAIN_USENATIVE, #True, #True, #True, @Status)
User avatar
Kwai chang caine
Always Here
Always Here
Posts: 5499
Joined: Sun Nov 05, 2006 11:42 pm
Location: Lyon - France

Re: EzTwain Freeware

Post by Kwai chang caine »

Not works
Always "Status: 0" and the IMA on line SysDestroy() :cry:
ImageThe happiness is a road...
Not a destination
infratec
Always Here
Always Here
Posts: 7662
Joined: Sun Sep 07, 2008 12:45 pm
Location: Germany

Re: EzTwain Freeware

Post by infratec »

Are you using PB x64 or x86?
User avatar
Kwai chang caine
Always Here
Always Here
Posts: 5499
Joined: Sun Nov 05, 2006 11:42 pm
Location: Lyon - France

Re: EzTwain Freeware

Post by Kwai chang caine »

Pb v5.60 LTS X86
After your question i have try with X64
But this time, PB is locked, and nothing happening :|
It's an old Canoscan 4200F, i love it, simple, faster, and i have bought several of this, for always use this model :mrgreen:
ImageThe happiness is a road...
Not a destination
Post Reply