| View previous topic :: View next topic |
| Author |
Message |
cristiam
Joined: 26 Jul 2010 Posts: 4
|
Posted: Wed Jul 28, 2010 5:41 am Post subject: ICAP_XFERMETH File + Duplex |
|
|
Hi,
I have a twain driver that is working with ICAP_XFERMETH file.
My problem is that i need to scan more than 300 pages in duplex mode and my machine stay with out of memory.
I want to set de ICAP_XFERMETH = TWSX_FILE to scan automaticaly to file.
I tryed:
| Code: |
rc = DSixfer(appid, srcds, TwDG.Image, TwDAT.ImageFileXfer, TwMSG.Get, ref hbitmap);
|
But It's saving only one file.
Anybody may help me?
PS: Sorry my bad english  |
|
| Back to top |
|
 |
peterp
Joined: 27 Jul 2010 Posts: 4 Location: Ottawa, ON
|
Posted: Thu Jul 29, 2010 6:02 am Post subject: Is it a multi page TIFF file? |
|
|
Many drivers use multi page TIFF files to save your result.
Is the single file a multi page TIFF file? Does the scanner actually scan all 300 pages, or does it stop scanning after one page? |
|
| Back to top |
|
 |
cristiam
Joined: 26 Jul 2010 Posts: 4
|
Posted: Thu Jul 29, 2010 6:04 am Post subject: Re: Is it a multi page TIFF file? |
|
|
| peterp wrote: | Many drivers use multi page TIFF files to save your result.
Is the single file a multi page TIFF file? Does the scanner actually scan all 300 pages, or does it stop scanning after one page? |
It's scanning all 300 pages but always save with the same filename. |
|
| Back to top |
|
 |
peterp
Joined: 27 Jul 2010 Posts: 4 Location: Ottawa, ON
|
Posted: Thu Jul 29, 2010 6:39 am Post subject: Is it a multi page TIFF file? |
|
|
Could you please answer the other question.
Is it a multi page TIFF file?
If not, what kind of file is it?
How big is the file?
A multi page TIFF file is a single file that can contain hundreds of pages inside itself. I suspect that your scanner is producing a multi page TIFF file and that every page that was scanned is there inside it. |
|
| Back to top |
|
 |
MSM
Joined: 17 May 2010 Posts: 10
|
Posted: Thu Jul 29, 2010 9:08 am Post subject: |
|
|
To do file transfer you have to do following:
1. Set ICAP_XFERMECH to TWSX_FILE
2. Set ICAP_IMAGEFILEFORMAT to one of supported by the driver formats
3. Enable DS
4. After you get MSG_XFERREADY, use DG_CONTROL / DAT_SETUPFILEXFER / MSG_SET to setup file name and file format (driver may not accept file format different from one set in ICAP_IMAGEFILEFORMAT )
5. Use DG_IMAGE / DAT_IMAGEFILEXFER / MSG_GET to do the transfer (Attantion!!! - last function parameter must be NULL)
6. Use DG_CONTROL / DAT_PENDINGXFERS / MSG_ENDXFER to find if there are more image. If Yes goto 4, if not continue
7. DisableDS
If you use single image file format (BMP, JPG..) change the name of the file before every transfer ().
If you use multi image file (TWFF_TIFFMULTI...) keep same file name |
|
| Back to top |
|
 |
cristiam
Joined: 26 Jul 2010 Posts: 4
|
Posted: Thu Jul 29, 2010 11:51 am Post subject: |
|
|
| MSM wrote: | To do file transfer you have to do following:
1. Set ICAP_XFERMECH to TWSX_FILE
2. Set ICAP_IMAGEFILEFORMAT to one of supported by the driver formats
3. Enable DS
4. After you get MSG_XFERREADY, use DG_CONTROL / DAT_SETUPFILEXFER / MSG_SET to setup file name and file format (driver may not accept file format different from one set in ICAP_IMAGEFILEFORMAT )
5. Use DG_IMAGE / DAT_IMAGEFILEXFER / MSG_GET to do the transfer (Attantion!!! - last function parameter must be NULL)
6. Use DG_CONTROL / DAT_PENDINGXFERS / MSG_ENDXFER to find if there are more image. If Yes goto 4, if not continue
7. DisableDS
If you use single image file format (BMP, JPG..) change the name of the file before every transfer ().
If you use multi image file (TWFF_TIFFMULTI...) keep same file name |
Thanks a lot.
My error is that i was trying to set DG_CONTROL / DAT_SETUPFILEXFER / MSG_SET BEFORE the MSG_XFERREADY.
Topic closed. |
|
| Back to top |
|
 |
|