Skip navigation
ThePulp75
Currently Being Moderated

Problem with Acrobat type library 10 with VB6 on Win7 64bit

Apr 14, 2011 6:54 AM

I'm trying to use the Acrobat type library 10 in a visual basic 6 source code on my Windows 7 64bit.

 

On the web I found many examples, and specifically i'm trying this one:

 

        'IAC objects

        Dim gAvDoc As Object

        Dim oPagesSrc As Long

        'variables

       

        bleFound = False

        ioutfile = FreeFile

        'hard coding for a PDF to open, it can be changed when needed.

        gPDFPath = "C:\Documents and Settings\....." ' FILL IN YOUR PATH HERE

       

        'Initialize Acrobat by creating App object

        Set gApp = CreateObject("AcroExch.App")

        gApp.Hide

       

        'Set PDDpc object

        Set gPDDoc = CreateObject("AcroExch.PDDoc")

 

But running this code I always get an error message: "the component can't create object" for line:

               Set gApp = CreateObject("AcroExch.App")

 

Really I don't know how can I fix....

 

Many thanks

 
Replies
  • Currently Being Moderated
    Apr 14, 2011 7:05 AM   in reply to ThePulp75

    We don't support VB6 with Acrobat X.

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 15, 2011 8:22 AM   in reply to ThePulp75

    Depends on what you want to do.

     

    If you simply want to view a pdf file, that still works using the ActiveX component.

    I have not seen problems in changing versions of Acrobat or Reader, since the ActiveX takes care of the viewer.

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 21, 2011 2:45 AM   in reply to ThePulp75

    The 64-bit system should not prevent you from using the ActiveX.

    But it is clear that VB6 is not the best choice if you are starting a new project. And Reader is not sufficient.

     

    If you simply want to check if the ActiveX works.

    Select the (Adobe .. Library) Reference/Component : this should put the AcroPDF element in the toolbox

    Drag the AcroPDF from the toolbox to your form

    Code to Load a file :  AcroPDF1.LoadFile "yourFile.pdf"

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points