Subject Re: printer paper source
From <rich@autotraker.com> <<rich@autotraker.com>>
Date Tue, 11 Aug 2020 14:21:46 -0400
Newsgroups dbase.getting-started

Mervyn did you get around to looking at the CC I posted?
That code is working with all the drivers I've tested including HP and we
have been using that code for over 10 years with no one reporting issues.
Rich....




"Mervyn Bick"  wrote in message news:hE0WtiAcWHA.1760@ip-AC1E04A7...

On 2020-08-11 18:43, Ken Mayer wrote:

> This is what I get:
>
> 0
> 0
....> 0
> 0

In other words, just a lot of nothing. :-)

It shows that, somehow, HP didn't get round to writing that last paper
name into the firmware.

If the code that prints out the results in PaperSize.prg and
PaperBin.prg is changed to the following it would ensure that there are
no blanks.

    local a, i
    a  =  getPapers( cDevice, "")
    for i = 1 to int((a.size + 1) / 2)
        ?     iif(a[i, 2] = '','?',a[i,2])
        ??    " - "
        ??    iif(a[i, 1] = '','?',a[i,1])
    endfor

What I find strange is that the Inspector can see the value for that
last paper name.  I wonder what dBASE uses to get the paper names.

Mervyn.