Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2009

    Unanswered: Writing to the registry

    I'm trying to make a subroutine that prints a report as a PDF to a preselected folder using Adobe Acrobat 6.0. I've figured out that in order to accomplish this, I first need to create a registry key located in HKEY_CURRENT_USER\Software\Adobe\Acrobat Distiller\PrinterJobControl\.

    The name of the key has to be the destination of the application doing the printing, so in this case, "C:\Program Files\Microsoft Office\Office\msaccess.exe" (without the quotes). And the value for this key has to be the location and name of the PDF being created, which will be stored in a variable called strPath.

    So I guess what this boils down to is a matter of using VBA to create a single key in the registry. Unfortunately, I can't figure out how to do that. Can anyone help?

  2. #2
    Join Date
    Aug 2009
    Update NY

    Post Writing to the registry

    I would explore the object in Arobat 6 to see if there is a way to set a value for the filename before writing to a computer registry.

    But to get sample code for writing to a registry, try this posting

    Reading and Writing Registry Values - Visual Basic(Microsoft): Version 5 & 6 FAQ - Tek-Tips

    Several other examples can be found by typing
    writing to registry:vba
    in google search

Posting Permissions

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