Re: Issue with EnumJobs and number of printed copies in Word
- From: "Mark Yudkin" <myudkinATcompuserveDOTcom@xxxxxxxxxxxxxx>
- Date: Tue, 13 Dec 2005 18:20:41 +0100
If you think it's a bug, open a support case against Word.
"denkouz" <denkouz@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:B3408B1B-B984-42AA-9FBD-23243D2283DA@xxxxxxxxxxxxxxxx
> It's my understanding that applications are supposed to populate the
> dmCopies
> field to report the printed number of copies and comply with the
> interface.
> To me, if Word subverts the interface and doesn't report dmCopies
> correctly,
> it's a bug.
>
> Also, if background printing is disabled, Word populates dmCopies with the
> correct number of copies but from the previous print job! If this is not a
> bug, what is it, a feature?
>
> It would be nice if a Microsoft representative shed some light on this,
> whether it's a bug or a "feature"...
>
>
> "Mark Yudkin" wrote:
>
>> IIRC, Word doesn't use the dmCopies features; rather it "internally"
>> prints
>> n copies. As far as Windows is concerned, there is only one copy.
>> Background
>> printing in Word merely means that a thread is spawned to do the actual
>> print processing on a document snapshot. Until the background printing is
>> through, there is no job in the Windows spooler.
>>
>> This is not a bug but the way Word was designed. As such, there is also
>> no
>> workaround, and you cannot retrieve any sensible information from the
>> spool
>> file either.
>>
>> "denkouz" <denkouz@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> news:719996B4-081D-48E2-A115-A095D47A4881@xxxxxxxxxxxxxxxx
>> > I'm using the EnumJobs WinAPI function to get the total number of pages
>> > printed to a printer. EnumJobs is populating a JOB_INFO_2 structure,
>> > and
>> > I'm
>> > getting the total pages printed in PagesPrinted * DEVMODE.dmCopies.
>> >
>> > It works fine with all applications except for MS Word. With Word
>> > background
>> > printing enabled, dmCopies is always 1 no matter how many copies of a
>> > document I print, and if background printing is disabled, dmCopies
>> > contains
>> > the number of copies of the previous print job!
>> >
>> > I'm having the same issue with Word 2000 - 2003 on different WinXP and
>> > Win2003 Server computers, with different printers and printer drivers.
>> > This
>> > looks like a Word bug to me... Is there a workaround for this problem?
>> > I
>> > know
>> > it's possible to get the number of copies from the spool file, but I'd
>> > rather
>> > not use this approach because the format of the spool files is
>> > undocumented.
>> >
>> > Thanks.
>> >
>>
>>
>>
.
- Follow-Ups:
- References:
- Re: Issue with EnumJobs and number of printed copies in Word
- From: Mark Yudkin
- Re: Issue with EnumJobs and number of printed copies in Word
- Prev by Date: Re: Constant values
- Next by Date: Re: vb netapi NT4 and W2K
- Previous by thread: Re: Issue with EnumJobs and number of printed copies in Word
- Next by thread: Re: Issue with EnumJobs and number of printed copies in Word
- Index(es):
Relevant Pages
|