English
Source / code snippets

List printer

 

CompileMarkSeparation
Source wurde am 15.07.2007 aus der MMJ-Quellcodesammlung (Dietmar Horn) in die Babyklappe auf XProfan.Com abgelegt:
Drucker auflisten
############### ##########
Drucker auflisten
Andreas Miethe * Juni 2003
##########################
DEF EnumPrinters(7) ! WINSPOOL.DRV,EnumPrintersA
DEF GetStandardPrinter(0) Substr$(ReadIni$(WIN.INI,Windows,Device),1,,)
DEF &PRINTER_ENUM_LOCAL 2
DEF &PRINTER_ENUM_DEFAULT 1
Declare PrinterValues#

Proc EnumPrinters

    Declare Printername&,Portname&,PrinterName$,PortName$,Attribs&
    Declare X&,dwNeeded&,dwReturned&
    EnumPrinters(&PRINTER_ENUM_LOCAL,0,5,0,0,ADDR(dwNeeded&),ADDR(dwReturned&))
    Dim PrinterValues#,dwNeeded&
    Clear PrinterValues#
    EnumPrinters(&PRINTER_ENUM_LOCAL ,0, 5, PrinterValues#, dwNeeded&, ADDR(dwNeeded&), ADDR(dwReturned&))

    While X& < dwReturned&*20

        Printername& = Long(PrinterValues#,x&)
        PrinterName$ = String$(Printername&,0)
        Attribs& = Long(PrinterValues#,x&+8)

        If AND(Attribs&,$4)

            Printername$ = Printername$ +  => Standarddrucker

        endif

        Print Printername$
        X& = X& + 20

    EndWhile

    Dispose PrinterValues#

Endproc

cls
EnumPrinters
Print
Print Standard-Drucker :
Print GetStandardPrinter()
waitinput
 
07/15/07  
 



Zum Quelltext


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

2.007 Views

Untitledvor 0 min.
Erasmus.Herold01/21/23
Rainer Hoefs07/05/19
GDL03/26/16
rquindt06/25/15
More...

Themeninformationen

this Topic has 1 subscriber:

unbekannt (1x)


Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie