QTP Scripting Doubts - III

Saandeep Sreerambatla

Saandeep Sreerambatla

@saandeep-sreerambatla-hWHU1M • Oct 21, 2024

Guys,

This article is for PDF automation.

I dont have any idea how to automate the PDF document.

So Guys please give the information of the required software for automating this !!

I will post my findings and code in a week time.

Replies

Welcome, guest

Join CrazyEngineers to reply, ask questions, and participate in conversations.

CrazyEngineers powered by Jatra Community Platform

  • Anil Jain

    Anil Jain

    @CrazyBoy Aug 6, 2009

    Try creating a PDF object, and use the methods:
    Example:

    Option Explicit
    Dim gApp, gPDDoc, jso
    Set gApp = CreateObject( "AcroExch.App" )
    Set gPDDoc = CreateObject( "AcroExch.PDDoc" )
    If gPDDoc.Open( "D:\Doc\AutomatedTesting.pdf" ) Then
    Msgbox gPDDoc.GetNumPages
    End If
    Set gPDDoc = Nothing
    Set gApp = Nothing

    Make sure that Adobe reader is installed on ths system for this type of the testing.

    -CB

  • Saandeep Sreerambatla

    Saandeep Sreerambatla

    @saandeep-sreerambatla-hWHU1M Aug 6, 2009

    oh! Thanks CB for the info..

    So we need to install Adobe Product for automating it, thanks !!

    I will post my experiences with it shorty , since i have to install the software and then try my hands on that.

  • Anil Jain

    Anil Jain

    @CrazyBoy Aug 6, 2009

    If you do not have adobe acrobat you will be getting a Run Error "ActiveX Component cannot create object: 'AcroExch.App' "

    For the use of the posted sample you must have an installation of Adobe Acrobat (I guess latest version is 9.x). The sample will not work with Adobe Reader.

  • Saandeep Sreerambatla

    Saandeep Sreerambatla

    @saandeep-sreerambatla-hWHU1M Aug 6, 2009

    Exactly i am facing the issue 😀