Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > alt.computer > #9820

Re: Excel problem

From Paul <nospam@needed.com>
Newsgroups alt.computer
Subject Re: Excel problem
Date 2016-02-29 16:20 -0500
Organization A noiseless patient Spider
Message-ID <nb2cgb$5or$1@dont-email.me> (permalink)
References <2v1By.9722$GB1.4097@fx28.iad>

Show all headers | View raw


Robert Baer wrote:
>   This used to work:
> 
>     vNam = Cells(2, 7).Text + "V"   'board voltage
>     pPath = "D:\ANALOG\HVREG\Boards\TITANTWO\TT_C\Jumpers\"
>     ActiveSheet.Shapes(1).Select
> ' ERROR: Method of 'Active Printer' of object '_Application' failed
> '  Application.ActivePrinter does not get set
>     Application.ActivePrinter = "Acrobat PDFWriter on FILE:"
>     ActiveWindow.SelectedSheets.PrintOut Copies:=1, Preview:=False, _
>     ActivePrinter:="Acrobat PDFWriter on FILE:", PrintToFile:=True, _
>     Collate:=False, PrToFileName:=pPath + vNam
> 
>     I does not matter what i set the default printer, the VB program 
> barfs the same way.
>   The Google groups 
> <https://groups.google.com/forum/#!forum/excel-macros> is useless; 
> nobody responds.
> 
>   Can this program problem be fixed?

Did you try a Google search on:

    Application.ActivePrinter = "Acrobat

That may bring up instances of the attempts
others have made to program it.

http://answers.microsoft.com/en-us/office/forum/office_2010-word/printout-to-pdf-but-pdf-corrupt/3cd5be2b-f6c5-4d23-82af-87a7ea8a1d6f?auth=1

It looks to me, like a typical link to such a pseudo device,
just uses its "given name", without the "on FILE" part
added to the end.

If you could get your macro to:

1) Put up a printer selection dialog box.
    Then, you click the Acrobat one.
2) Back in the script, pop up a dialog box with
    the string that came from the selection.
3) Now, you know what to call it.

    Paul

Back to alt.computer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Excel problem Robert Baer <robertbaer@localnet.com> - 2016-02-29 12:04 -0800
  Re: Excel problem Paul <nospam@needed.com> - 2016-02-29 16:20 -0500
    Re: Excel problem Robert Baer <robertbaer@localnet.com> - 2016-03-02 08:58 -0800
  Re: Excel problem VanguardLH <V@nguard.LH> - 2016-02-29 17:32 -0600
    Re: Excel problem Robert Baer <robertbaer@localnet.com> - 2016-03-02 08:59 -0800

csiph-web