Article View: borland.public.cppbuilder.nativeapi
Article #15116Re: TPrinter Problem
From: Remy Lebeau (TeamB)
Date: Wed, 16 Jul 2003 03:41
Date: Wed, 16 Jul 2003 03:41
25 lines
1933 bytes
1933 bytes
"Anthony" <awhitesell@attbi.com> wrote in message
news:3f1496ff@newsgroups.borland.com...
> I am in the process of rewriting my routines to use
> ::TextOut, ::MoveTo, and ::LineTo instead of
> Canvas->TextOut, MoveTo, LineTo.
What's wrong with using the TCanvas methods?
> I am using Printers()->Printers->Strings[] to list the available
> printers in a combo box to select a printer. Is there an easy
> way to relate the selected printer to its handle in light of the
> current Handle issue.
The TPrinter::Handle is obtain dynamically each time it is queried, it is
not stored or reused. If you want to get a handle then you already know
what to do - use CreateIC/DC() or OpenPrinter() directly.
> int marker=printer_string.Pos("on");
Try using " on " instead of "on" (notice the extra spaces).
Gambit
Technical Details
Message-ID:
<3f14c841$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-06!sn-xit-09!supernews.com!diablo.theplanet.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<3f1460f3$1@newsgroups.borland.com> <3f14693d$1@newsgroups.borland.com> <3f1471c0$1@newsgroups.borland.com> <3f147649$1@newsgroups.borland.com> <3f1496ff@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10cc67,d59131589fe63384 X-Google-Attributes: gid10cc67,public X-Google-ArrivalTime: 2003-07-15 20:41:48 PST From: "Remy Lebeau \(TeamB\)" <gambit47@yahoo.com> Newsgroups: borland.public.cppbuilder.nativeapi References: <3f1460f3$1@newsgroups.borland.com> <3f14693d$1@newsgroups.borland.com> <3f1471c0$1@newsgroups.borland.com> <3f147649$1@newsgroups.borland.com> <3f1496ff@newsgroups.borland.com> Subject: Re: TPrinter Problem Date: Tue, 15 Jul 2003 20:41:48 -0700 Lines: 27 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 NNTP-Posting-Host: 207.175.226.26 Message-ID: <3f14c841$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1058326593 207.175.226.26 (15 Jul 2003 20:36:33 -0700) Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-06!sn-xit-09!supernews.com!diablo.theplanet.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail