🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #12610

Re: Windows Printers

#12610
From: John Scott
Date: Sun, 30 Nov 2003 17:04
20 lines
1690 bytes
Thanks for your response. I have tried the following but get an error, could
you point out the correct syntax?

    char *ADevice, *ADriver, *APort;
    int  ADeviceMode;
    DEVMODE DMode;
    //ADeviceMode=DMode;
    Printer()->GetPrinter(ADevice, ADriver, APort, DMode);
    Printer()->SetPrinter(ADevice, ADriver, APort, DMode);

Thanks - John

>
> This is a known issue with the TPrinter Object. What you need
> to do is to set the Printer()->PrinterIndex and then use
> Printer->GetPrinter followed by Printer()->SetPrinter to
> ensure that the Printer()->Handle is valid.
>
> ~ JD
>
Technical Details
Message-ID: <3fca2347@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.media.kyoto-u.ac.jp!newsfeed.icl.net!newsfeed.fjserv.net!colt.net!peernews3.colt.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <3fbcf9c2@newsgroups.borland.com> <3fbd8132$1@newsgroups.borland.com> <3fc77301@newsgroups.borland.com> <3fc7e524$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,7b2449597708bec
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-11-30 09:09:08 PST
From: "John Scott" <jscott@kw.igs.net>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3fbcf9c2@newsgroups.borland.com> <3fbd8132$1@newsgroups.borland.com> <3fc77301@newsgroups.borland.com> <3fc7e524$1@newsgroups.borland.com>
Subject: Re: Windows Printers
Date: Sun, 30 Nov 2003 12:04:12 -0500
Lines: 22
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
NNTP-Posting-Host: 216.16.227.123
Message-ID: <3fca2347@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1070211911 216.16.227.123 (30 Nov 2003 09:05:11 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newsfeed.media.kyoto-u.ac.jp!newsfeed.icl.net!newsfeed.fjserv.net!colt.net!peernews3.colt.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail