+ Reply to Thread
Results 1 to 4 of 4

[SOLVED] List of available printers

  1. #1
    prizm1
    Guest

    [SOLVED] List of available printers

    I am trying to develop a form that will dynamically find and list all
    available printers including the default printer. From this form I want
    to select which printer will be assigned to Application.ActivePrinter.
    How do I write a macro to provide the names of all available printers?

  2. #2
    Don Guillett
    Guest

    Re: List of available printers

    Does this help?

    Sub getprinters()
    Application.Dialogs(xlDialogPrinterSetup).Show
    End Sub

    --
    Don Guillett
    SalesAid Software
    [email protected]
    "prizm1" <[email protected]> wrote in message
    news:[email protected]...
    > I am trying to develop a form that will dynamically find and list all
    > available printers including the default printer. From this form I want
    > to select which printer will be assigned to Application.ActivePrinter.
    > How do I write a macro to provide the names of all available printers?




  3. #3
    prizm1
    Guest

    Re: List of available printers

    That's something I can resort to, just displaying the Print dialog and
    having the user select from their list of printer names.

    The thing is, as I change workstations, the printers available to me
    from the on-network Excel file I'm designing can change. Some stations
    have the network printer as default while others have a locally attached
    printer as default. I am trying to create a form that offers the user a
    choice between the locally attached printer and the network printer. It
    would be great if I could access the Print Dialog Name drop-down list of
    printers directly in VBA and import them into a list box user form
    unique to that workstation. The form would list both the network printer
    and the printer local to that workstation (just as the Print dialog
    does)with the local printer attached to that particular comp being
    different from what would be listed for a different workstation with a
    different locally attached printer.

    Since the Macro Recorder can "extract" the printer names, I assume that
    there must be some obscure VBA code I can manually enter to get at these
    local, unique-station printer names directly.



    Don Guillett wrote:
    > Does this help?
    >
    > Sub getprinters()
    > Application.Dialogs(xlDialogPrinterSetup).Show
    > End Sub
    >


  4. #4
    Don Guillett
    Guest

    Re: List of available printers

    look at this
    http://tinyurl.com/8pz5c

    --
    Don Guillett
    SalesAid Software
    [email protected]
    "prizm1" <[email protected]> wrote in message
    news:[email protected]...
    > That's something I can resort to, just displaying the Print dialog and
    > having the user select from their list of printer names.
    >
    > The thing is, as I change workstations, the printers available to me
    > from the on-network Excel file I'm designing can change. Some stations
    > have the network printer as default while others have a locally attached
    > printer as default. I am trying to create a form that offers the user a
    > choice between the locally attached printer and the network printer. It
    > would be great if I could access the Print Dialog Name drop-down list of
    > printers directly in VBA and import them into a list box user form
    > unique to that workstation. The form would list both the network printer
    > and the printer local to that workstation (just as the Print dialog
    > does)with the local printer attached to that particular comp being
    > different from what would be listed for a different workstation with a
    > different locally attached printer.
    >
    > Since the Macro Recorder can "extract" the printer names, I assume that
    > there must be some obscure VBA code I can manually enter to get at these
    > local, unique-station printer names directly.
    >
    >
    >
    > Don Guillett wrote:
    > > Does this help?
    > >
    > > Sub getprinters()
    > > Application.Dialogs(xlDialogPrinterSetup).Show
    > > End Sub
    > >




+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1