AcroExch.AVDoc.FindText()

Hi, there
Does anyone have any experience of the FindText() function? I was hoping to use it together with acrApp.MenuItemExecute "NewBookmark" to create a set of standard bookmarks. The API documentation claims that the function "Finds the specified text, scrolls so that it is visible, and highlights it" and it returns "True if the text was found, False if it was not." From my experience, though, it always returns True, and certainly doesn't scroll to the text or highlight it. In fact, all it seems to do is insert the find text in the application's search field.
Or am I doing summit wrong?
Dim acrApp, acrAVDoc
Set acrApp = CreateObject("AcroExch.App")
Set acrAVDoc = CreateObject("AcroExch.AVDoc")
acrApp.Show
If acrAVDoc.Open(MY_FILE, "") Then
acrAVDoc.FindText MY_TEXT, False, True, True
etc...
thanks
jON
- Adobe Acrobat 6.0
- MS Office 2003
- MS Windows XP Professional SP2

For me it works correct - I only dislike the msgbox "not found", when the value is false.
Another way would be be to read the text of the page(s) and anlyse it in VBS.
Attached a code snipet for that.
HTH, Reinhard
'// Save this as xxx.vbs and start with Double Click
'// It gives you the text of an already opened PDF
'// if Acrobat or no Doc is open you get an ErrorMsg
set WshShell = CreateObject ("Wscript.Shell")
WshShell.AppActivate("Adobe Acrobat")
WScript.Sleep 500
'// get the active Document
Set AcroApp = CreateObject("AcroExch.App")
Set AVDoc = AcroApp.GetActiveDoc
Set PDDoc = AVDoc.GetPDDoc
Set PdfPage = PDDoc.AcquirePage(1) '<<--SET in FILE! =Pagenumber
Set PageHL = CreateObject("AcroExch.HiliteList")
PageHLRes = PageHL.Add(0,9000) '<<--SET in FILE! (Start,END[9000=All])
Set PageSel = PdfPage.CreatePageHilite(PageHL)
for i = 0 to PageSel.Getnumtext - 1
pdfData =PDFData & PageSel.GetText(i)
Next
msgBox PDFDATA

Similar Messages

  • AcroExch.AVDoc.FindText(), Acrobat XI

    Code from Chapter 16 Scripting Quicktest Professional Page 25,  Dani Vainstein
    FindText(): Finds the specified text,
    but doesn't scrolls so that it is visible, and doesn't highlights it
    Dim AcroApp, AcroAVDoc As Object
    Dim gPDFPath, bReset, nCount
    gPDFPath = "c:\Input.pdf"
    Set AcroApp = CreateObject("AcroExch.App")
    AcroApp.Show
    Set AcroAVDoc = CreateObject("AcroExch.AVDoc")
    If AcroAVDoc.Open(gPDFPath, "") Then
    AcroAVDoc.BringToFront
    bReset = True: nCount = 0
    Do While AcroAVDoc.FindText("9630208046", True, True, bReset)
    bReset = False: nCount = nCount + 1
    Loop
    End If
    AcroApp.CloseAllDocs
    AcroApp.Exit
    Print "The word '9630208046' was found " & nCount & " times."
    Set AcroApp = Nothing
    End Sub
    With Acrobat 9 and Access the program works. Is there a Workaround for Acrobat XI.

    For me it works correct - I only dislike the msgbox "not found", when the value is false.
    Another way would be be to read the text of the page(s) and anlyse it in VBS.
    Attached a code snipet for that.
    HTH, Reinhard
    '// Save this as xxx.vbs and start with Double Click
    '// It gives you the text of an already opened PDF
    '// if Acrobat or no Doc is open you get an ErrorMsg
    set WshShell = CreateObject ("Wscript.Shell")
    WshShell.AppActivate("Adobe Acrobat")
    WScript.Sleep 500
    '// get the active Document
    Set AcroApp = CreateObject("AcroExch.App")
    Set AVDoc = AcroApp.GetActiveDoc
    Set PDDoc = AVDoc.GetPDDoc
    Set PdfPage = PDDoc.AcquirePage(1) '<<--SET in FILE! =Pagenumber
    Set PageHL = CreateObject("AcroExch.HiliteList")
    PageHLRes = PageHL.Add(0,9000) '<<--SET in FILE! (Start,END[9000=All])
    Set PageSel = PdfPage.CreatePageHilite(PageHL)
    for i = 0 to PageSel.Getnumtext - 1
    pdfData =PDFData & PageSel.GetText(i)
    Next
    msgBox PDFDATA

  • QTP-11 doesn't recognize "AcroExch.AVDoc" object with "Adobe Acrobat 9.0"

    Hi Support Team,
    I worked with Acrobat 7 and have used the same script after installing Acrobat 9 for Automation Testing with QTP for validating pdf. The object "AcroExch.AVDoc" is not getting identified as object while working in QTP-11 in the system/machine which has Acrobat 9 installed, whereas it works well in the machine which has Acrobat 7 installed . So it will be better if two things are known as per my understanding, ie.,
    it must have compatibility issue (i need links/wweb-source about the difference between "Adobe Acrobat versions 7 & 9" to assure this) or
    installation issue( which can be confirmed if the former question is answered).
    So i kindly request you to help me out for this scenario.
    Kind Regards,
    Vikraman G

    You need the Adobe PDF Test Toolkit - http://labs.adobe.com/technologies/aptt/

  • Hello, I have the usual issue to use AcroExch.PDDoc/AcroExch.App/AcroExch.AVDoc objects in Visual Basic (MS EXCEL). On my company's machine I have Acrobat X and everything works fine, but I have another machine with just "Reader" installed - is there als

    Hello, I have the usual issue to use AcroExch.PDDoc/AcroExch.App/AcroExch.AVDoc objects in Visual Basic (MS EXCEL). On my company's machine I have Acrobat X and everything works fine. I am looking for the cheapest solution to get the stuff running on another machine... is there any way to do that with the Acrobat SDK, or do I need to purchase a full version of Acrobat XI ($$) ?

    The Acrobat SDK is nothing by itself. It is just information on how to automate Acrobat - just as the Office SDK doesn't include Office, but is for people who already have purchased Office but want to automate it.
    These automation things are MARKETING TOOLS FOR ACROBAT. Consider this and the technical limitations make a lot more sense.
    So, yes, you need to buy Acrobat. Standard is cheaper than Pro.

  • How do I pass the number of print copies to AcroExch.AVDoc

    Hi,
    I have the following function to print a pdf file, but I don't seem to be able to specify the number of copies I want to print, please help! How to set the number of copies to print, thanks a lot!
    Sub PrintPDF(ByVal pdfFilePath As String, ByVal numCopyToPrint As Integer)
    'AcroPDF1.Application
    Call GetCommandBarNames
    Dim myAcroApp As AcroApp
    Dim myAVDoc As AcroAVDoc
    Dim PDDoc As AcroPDDoc
    Dim numPages As Integer
    Dim IsSuccess As Boolean
    Set myAcroApp = CreateObject("AcroExch.App")
    Set myAVDoc = CreateObject("AcroExch.AVDoc")
    myAVDoc.Open pdfFilePath, ""
    Set PDDoc = myAVDoc.GetPDDoc
    numPages = PDDoc.GetNumPages
    myAcroApp.Show
    'MsgBox "numpages = " & numPages & ", numcopies = " & numCopyToPrint
    'myAVDoc.PrintPages 1, numPages, numCopyToPrint, True, True
    myAVDoc.PrintPages 1, numPages, 2, True, True
    'Close the PDF
    myAVDoc.Close True
    myAcroApp.Hide
    myAcroApp.CloseAllDocs
    myAcroApp.Exit
    'Cleanup
    Set PDDoc = Nothing
    Set myAVDoc = Nothing
    Set myAcroApp = Nothing
    End Sub

    You cannot. (Note to other readers: this is an API to Acrobat, not
    Adobe Reader)
    Aandi Inston

  • Extract highlighted words from a pdf (Acrobat SDK, OLE)

    Hello Acrobat gurus ! :-)
    I'm new to the SDK, so please excuse any "stupid" question i might have.
    Here is what i want to do:
    I want to search for a group of words in a pdf document. According to the SDK documentation, once i search for a text using AcroExch.AVDoc.FindText(), the function "Finds the specified text, scrolls so that it is visible, and highlights it."
    I was assuming that after calling this function with my string, once the string is found i will have acces to the coordinates of the rectangle containing the highlighted group of words (i presumed that those words would be automatically contained in an object of the type AcroExch.HiliteList) and to the coordinates of those words.But i'm not able to do so, i cannot find any function(s) that give me that kind of access.
    So question is:
    Is it possible to access the coordinates of the rectangle/words that are highlighted in a pdf after calling the FindText() function ? Can someone help me get on the right track ?
    Thanks

    Ok, let me give you an more elaborate example, maybe i don't ask the right question.
    Let's say i have a pdf, containing the following text in the first page
    --- arbitrary number of ":"
    Mother's Name: Joanna
    Father's Name: Josh
    other text
    If i call the function like this: FindText("Mother's Name:"), acrobat is going to find the first occurance of my string. What i want to do is to be able to get the coordinates of this WHOLE string OR the coordinates of the last character in the string  (in this case ":").
    The problem is that if i go for the coordinates ofthe double dots i cannot just look for them in the pdf, because i may have an unknown number of double dots (":") before the ones i'm interested in. The logical solution in this case would be to get the coordinates of the entire string ("Mother's Name:" in this case) and then get the coordinates of the double dots i'm interested in.
    Would that be possible ?

  • .FindText() infinite loop problem

    My company has a need to count how many times certain words are in a PDF document while doing automated testing.  We're using QuickTest Professional and it's programming language is VBScript.  Now I attempted to use the example code from the SDK manual but when I run it it's in an infinite loop.  Once it's gone through the document one time, it jumps back up to the top and counts it again and continue doing this until I either kill the process or kill Acrobat.  My code is attached though it's not much different from the example.  If anyone could help I would be greatly appreciative.
    Option Explicit
    Dim AcroApp, AcroAVDoc
    Dim gPDFPath, bReset, nCount
    gPDFPath = "C:\Documents and Settings\HicksAM\Desktop\Organize Later\DemoDoc.pdf"
    Set AcroApp = CreateObject("AcroExch.App")
    'AcroApp.Show()
    Set AcroAVDoc = CreateObject("AcroExch.AVDoc")
    If AcroAVDoc.Open(gPDFPath, "") Then
         AcroAVDoc.BringToFront()
         bReset = 1 : nCount = 0
         Do While AcroAVDoc.FindText("DRIVER", True, True, bReset)
              bReset = false : nCount = nCount + 1
    '         If Window("Adobe Acrobat").Dialog("Adobe Acrobat").Exist(0) Then
    '               Window("Adobe Acrobat").Dialog("Adobe Acrobat").WinButton("OK").Click
    '               Exit Do
    '          End If
              Wait 0, 200
         Loop
    End If
    AcroApp.CloseAllDocs()
    AcroApp.Exit()
    Print "The word DRIVER was found " & nCount &" times."
    Set AcroApp = Nothing

    This is from the documentation that came with the SDK:
    "Since the JavaScript code runs slowly, it is not suitable for searching through a large PDF file."  I work for an insurance company and the documents can get
    quite lengthy. Not only that, I would need native methods to Acrobat that I can send directly from QTP without having to import specific header/import files.  Just as the example posted in the original post, I could actually get it to search correctly without using any of the SDK files, but it loops infinitely instead of stopping at the end of the PDF document.

  • AcroExch - Acrobat SDK 9.0

    Hi,
    I have a copy of Adobe Acrobat 9 pro installed along with the SDK.  I can run the BasicIACVB example and have used the sample to find text in the pdf, however I am having issues pulling the actual page number that the text is found on.
    I am using the ACROBAT.CACROAVPAGEVIEW object.
    Dim gAVPage as Acrobat.CAcroAVPageView
    gAvPage = CreateObject("AcroExch.CAcroAVPageView")
    I get an error stating "Cannot create ActiveX component." on the second line, the CreateObject line.
    I can create an object of AcroExch.AVDoc just fine without errors.
    Any Suggestions would be greatly appreciated.  Oh, I am developing in VB.net 2005 on a Windows XP Pro Box.
    Thanks!
    JT

    You should post in the Acrobat SDK forum.

  • AcroExch.App with Adobe Reader

    If a computer only has Adobe Reader installed, can an application running on that computer interact with a pdf document via OLE?  In particular, can an application on that computer use AcroExch.App and AcroExch.AVDoc objects?
    Example code:
    #import "acrobat.tlb" rename_namespace("ACROBAT"), auto_rename
    ACROBAT::CAcroAppPtr app("AcroExch.App");
    ACROBAT::CAcroAVDocPtr avDoc("AcroExch.AVDoc");
    ACROBAT::CAcroPDDocPtr pdDoc;
    avDoc->Open(TEXT("c:\\example.pdf"), TEXT(""));
    pdDoc = avDoc->GetPDDoc();
    pdDoc->OpenAVDoc("Title");
    Currently creating app gives error: Invalid class string
    Thanks!

    Hi Athirukk
    from above posts, it appear you have worked good deal to edit pdf docs without using SDK ( with the help of plugins/DDE).
    can you please help me what was the result . as i have the similar issue (ActiveX is not able to create objects for data points i have in the code @  http://forums.adobe.com/message/4109842 ).
    apprciate any guidance.
    regards
    Sidharth

  • .FindText not respecting parameters in Acrobat 10

    Hello to all,
    New to programming with Adobe. Experienced in MS Office VBA.
    I have some code in VBA (EXCEL) that opens pdf files (created from WORD 2007 and searchable) and searches each one for a series of key words.
    The example below works fine on Acrobat 8, but not on my newly installed Acrobat 10 (Acrobat X version 10.0.0).
    The text to find is "CO" (whole word only, case sensistive) - not present as such in the test pdf file, but the word "COMMITTEE" is.
    The code used is: spfd = AVDoc.FindText("CO", 1, 1, 1)
    This results in spfd=False for Acrobat 8 (which is correct), but results in spfd=True in acrobat 10.
    If I do the same search through the Acrobat application interface on the same pdf file, specifying whole words only & case sensitive, it does not find a match, which is correct.
    Any thoughts?
    Many thanks in advance for any help!
    timo_mika

    Hello to all,
    This is justto say that the problem also occurs on a brand new machine with new Acrobat X installation. Any help would be appreciated, including other methods to find text (over 100 key words, noting that some of the strings contain more than one word...).
    Thanks!

  • "Invalid Variant Operation" when AVDoc.GetPDDoc

    Hi, I create pdf object by ole in delphi.
    =====================
        try
            AcroApp := CreateActiveXObject('AcroExch.App');
            AcroApp.Hide;
        except
            Exit;
        end;
             AcroAVDoc := CreateActiveXObject('AcroExch.AVDoc');
            if not AcroAVDoc.Open(strFileName, '') then begin
                Exit;
            end;
            AcroAVDoc := AcroApp.GetActiveDoc;
            AcroPDDoc := AcroAVDoc.GetPDDoc;  <-- throw invalid variant operation exception
         AcroPDDoc.Save(1, strFileName);
    ==========================
    In fact, If I can save the document, do not know if there is no other way to bypass the pddoc, if only with pddoc, is not playing some of the patches can

    Attached a sample VBS. Save it as ...vbs and doubleclick on it.
    If it works for you, ask in the delphi forum, how to translate.
    HTH, Reinhard
    AcroTestSave.vbs
    fileIn = "C:\Test.pdf"                         '// state the full path of the file to open
    FileOut = "C:\Test3.pdf"                  '// state the full path for the file to save
    set App = CreateObject("AcroExch.App")            '// start Adobe Acrobat
    App.Show                                                      '// show Acrobat
    Set AVDoc = CreateObject("AcroExch.AVDoc") '// connect to  Ac Viewer
    AVDoc.Open fileIn,""                                '// Open a file into viewer
    set PDDoc = AVDoc.GetPDDoc             '// Get the Doc opened in the viewer
    set JSO = PDDoc.GetJSObject            '// Connect to Acrobat JS
    JSO.app.alert("Hi, the file is open press Ok and I'll save it")  '// Display a MsgBox
    PDDoc.Save 3,fileOut                             '// SaveAs
    App.CloseAllDocs                                       '// close all docs
    set JSO = nothing
    set AvDoc = nothing
    set PdDoc = nothing
    set App = nothing

  • Acrobat won't release a file

    Everyone,
    I'm using visual basic to manipulate a pdf file opened in Acrobat. The code below opens the file and searches for a text string. If it finds the text string, the pages containing are deleted. Once the text string is no longer found, the file is closed, the application is hidden and then exited. All of this works just fine.
    My problem occurs with the last line of code. I want to rename the file and place it in another directory. However, I get a file path error which indicates to me that Acrobat is still holding on to the recently closed file.
    Is there a method to get Acrobat to release the file? Any help is appreciated.
    MikeCJ
    Dim pdfAcroExchApp As Acrobat.AcroApp
    Dim pdfAVDoc As Acrobat.AcroAVDoc
    Dim pdfPDDoc As Acrobat.AcroPDDoc
    Dim pdfPath, sText As String
    Dim foundText, Rsp, x As Integer
    Dim check As Boolean
    'Check establishes whether an MSDS has a chemical Evaluation form attahced.
    check = True
    Do While check = True
        'If the text string frmChemEval is found it is a certainty the MSDS file contains a Chemcial Evaluation Form
        sText = "frmChemEval"
        pdfPath = "Q:\" & Form_frmControlPanel.fldautoMSDSNbr & ".pdf"
        'set pdfAVDoc for searching
        Set pdfAcroExchApp = CreateObject("AcroExch.App")
        Set pdfAVDoc = CreateObject("AcroExch.Avdoc")
        pdfAVDoc.Open pdfPath, ""
        pdfAcroExchApp.Show
        Set pdfPDDoc = pdfAVDoc.GetPDDoc
        Set pdfPDDoc = CreateObject("AcroExch.PDDoc")
        pdfPDDoc.Open pdfPath
        x = pdfPDDoc.GetNumPages
        foundText = pdfAVDoc.FindText(sText, 0, 1, 1)
            If foundText = -1 Then
                check = True
            Else
                check = False
            End If
            If check = True Then 'The MSDS already contains a Chemical Evaluation Form
                    pdfPDDoc.AcquirePage pdfPDDoc.GetNumPages - 1
                    pdfPDDoc.DeletePages pdfPDDoc.GetNumPages - 1, pdfPDDoc.GetNumPages - 1
            End If
    Loop
    pdfPDDoc.Close
    pdfAcroExchApp.Hide
    pdfAcroExchApp.Exit
    Name (pdfPath) As ("Q:\MSDS Temp\MSDStoMerge.pdf")

    Bernd,
    It was an omission on my part. I've included a save statement just before the close statement. Any thoughts of the "releasing" issue?
    Thanks,

  • How to search a word and its page in Acrobat 6.0 using vb6.0

    Hi all,
    I would like to search a word and its corresponding page number in my PDF document. The word may be occur in many of the pages and i have to collect all the page numbers and need to create bookmark for all of them.
    Eg: The word "Chennai" can be found in the pages 5, 6, 7 and10. Then I need to create bookmarks Chennai1 - Page 5, Chennai2 - Page 6 and so on...
    I have tried this with Acrobat 7.0 professional and it was working fine. But in 6.0 Professional i am not able to collect all the pages. Below I have given the code that i have used.
    Dim objFind As Acrobat.CAcroAVDoc
    Set objFind = CreateObject("AcroExch.AVDoc")
    Do While objFind.FindText("MyText", 0, 1, False)
                    Dim objPageView As Acrobat.CAcroAVPageView
                    Set objPageView = objFind.GetAVPageView
                    strPageNo = objPageView.GetPageNum + 1
                    If strPageNo = strPrevPageNo Then
                        intIncremental = intIncremental + 1
                    Else
                        intIncremental = 0
                    End If
                    If intIncremental > 50 Then
                        Exit Do
                    End If
                    If Val(strPageNo) < Val(strPrevPageNo) Then
                        Exit Do
                    End If
                    strPrevPageNo = strPageNo
    Loop
    Thanks in advance,
    Dhanasekaran. G

    Adobe no longer supports Acrobat 7 or earlier.

  • How do I call an object written in Plugin from Javascript in Acrobat 9.0?

    Hi,
    Since Acrobat 9.0 has no longer support  GetNumAVDocs() called in Javascript, it does not return number counter of opened pdf documents.
    I am looking for a way to write method GetNumAVDocs() or similar one in Plug-in. My questions are that
    1. Can we write the method  GetNumAVDocs() or similar in Plug-in?
    2. Can we integrate that method GetNumAVDocs() which written in Plug-in in Javascript or Can Javascript call that method GetNumAVDocs()?
    Any of your comments or advices are very helpful to me.
    Thanks a lot for your support,
    Thai Nguyen

    Hi lrosenth,
    Thank you for help so far. In fact we our codes have been using COM/ActiveX and AcroExch.App library along. These codes are working find with Acrobat 8.0, but they do not work with Acrobat 9.0 since the function GetNumAVDocs() is no longer working. It always returns 0, instead of maximum number of documents.
    I would like to attach the code along with PDF documents for you to take a look and help us. This zip file is test1.zip.  This zip file include a html file test1.html. This file includes HTML page and a number of Javascript/Activex functions. 
    The function getActiveDoc() is the target of the issue. It contains an AcroExch.App function GetNumAVDocs() which does not return a number of the maximum number of documents the Acrobat application can open on Acrobat 9.0. It always returns 0 regardless how many how many documents are opened.
    At the bottom of the source code is html page that called the function getActiveDoc()  at the <input>  tag.  <input type="button" value="Show Active Docs" onclick="getActiveDoc();">
    For testing this code, you unzip test1.zip file. Open test1.html on a web browser. It will load couple pdf files that include on test1.zip.  Click on button "Show Active Docs" that calls function getActiveDoc().  This function trigger GetNumAVDocs(). It then call alert(numdoc)  to display a value of number of opened documents.
    Thank you,
    Thai Nguyen
    -------------------------------The Codes below-------------------------------------
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Test for Adobe 8&amp;9</title>
    </head>
    <script type="text/javascript">
    function nextPage(){
    var acrobatpdf= document.getElementById("acrobatpdf");
    acrobatpdf.GotoNextPage();
    function prevPage(){
    var acrobatpdf= document.getElementById("acrobatpdf");
    acrobatpdf.GotoPreviousPage();
    function showToolbar(){
    var acrobatpdf= document.getElementById("acrobatpdf");
      acrobatpdf.setShowToolbar(1);
    function hideToolbar(){
    var acrobatpdf= document.getElementById("acrobatpdf");
      acrobatpdf.setShowToolbar(0);
    function loadfile(){
    var file = document.getElementById("file").value;
    alert(file);
    var acrobatpdf= document.getElementById("acrobatpdf");
    var rtn = acrobatpdf.LoadFile(file);
    alert(rtn);
    function getActiveDoc(){
    var acrobatapp= document.getElementById("acrobatapp");
    var numdoc = acrobatapp.GetNumAVDocs();
    alert(numdoc);
    for(i=0;i < numdoc;i++){
      actDoc = acrobatapp.getIEPDFDoc();
      var actDoc = acrobatapp.GetAVDoc(i);
      alert("item:"+i);
      if(actDoc!=null){
              var title = actDoc.GetTitle();
        alert(title);
      }else{
       alert("Null object");
    function findText(){
    var file = "D:\\lab\\adobe\\test1\\fcom012360.pdf";
    var text = document.getElementById("findtext").value;
    var acrobatapp= new ActiveXObject("AcroExch.App");
    var avdoc= new ActiveXObject("AcroExch.AVDoc");
    var acrobatpdf= document.getElementById("acrobatpdf");
    var x = acrobatpdf.LoadFile(file);
    alert(x);
    </script>
    <body>
    <div>
    <input type="button" value="Next Page" onclick="nextPage();">
    <input type="button" value="Prev Page" onclick="prevPage();">
    <input type="text" id="file" width="80">
    <input type="button" value="Load File" onclick="loadfile();">
    <input type="button" value="Show toolbar" onclick="showToolbar();">
    <input type="button" value="Hide toolbar" onclick="hideToolbar();">
    </div>
    <div>
    <input type="button" value="Show Active Docs" onclick="getActiveDoc();">
    <input type="text" id="findtext" width="80">
    <input type="button" value="Find Text" onclick="findText();">
    </div>
    <div>
        <OBJECT id="acrobatapp"
                classid="clsid:85DE1C45-2C66-101B-B02E-04021C009402">
        </OBJECT>
        <OBJECT id="avdoc"
                classid="clsid:72498821-3203-101B-B02E-04021C009402">
        </OBJECT>
        <OBJECT classid="clsid:CA8A9780-280D-11CF-A24D-444553540000"
                width="960" height="492" id="acrobatpdf"
                style="WIDTH: 784px; HEIGHT: 492px">
         <PARAM NAME="_cx" VALUE="26035">
            <PARAM NAME="_cy" VALUE="15663">
            <Param name="SRC" value="fcom012330.pdf">
        </OBJECT>
    </div>
    </body>
    </html>

  • Find an highlight text with Excel vba an Acobat XI Pro

    Hello,
    i want to write a VBA Script to search for and highlight text.
    Until now my Script open the PDF and search for text. But how can i highlight it ?
    Thank you.
    Axel
    My Code :
    Sub OpenPDFPageView()
        Dim PDFApp As AcroApp
        Dim PDFDoc As AcroAVDoc
        Dim PDFPageView As AcroAvPageView
        Dim PDFPath As String
        Dim DisplayPage As Integer
        PDFPath = "C:\Users\info_000\Desktop\test.pdf"
        'Set the page you want to be displayed
        DisplayPage = 1
        'Initialize Acrobat by creating App object
        Set PDFApp = CreateObject("AcroExch.App")
        'Set AVDoc object
        Set PDFDoc = CreateObject("AcroExch.AVDoc")
        'Open the PDF
        If PDFDoc.Open(PDFPath, "") = True Then
            PDFDoc.BringToFront
            'Maximize the document
            Call PDFDoc.Maximize(True)
            Set PDFPageView = PDFDoc.GetAVPageView()
            'Go to the desired page
            'The first page is 0
            Call PDFPageView.GoTo(DisplayPage - 1)
            'Set the page view of the pdf
            Call PDFPageView.ZoomTo(2, 50)
        End If
        If PDFDoc.FindText("blabla", 1, 1, 1) = True Then
            Debug.Print "gefunden"
            call pdfdoc.
        Else
            Debug.Print "nicht gefunden"
        End If
        Set PDFApp = Nothing
        Set PDFDoc = Nothing
        On Error Resume Next
        'Show the adobe application
        PDFApp.Show
        'Set the focus to adobe acrobat pro
        AppActivate "Adobe Acrobat Pro"
    End Sub

    With Acrobat Javascript you can search for words, retrieve the position of the found words, and add annotations at this positions.

Maybe you are looking for

  • Is there any way to transfer music from my iphone 4s to my new itunes library?

    A few weeks ago i tried to clear up some space on my laptop and deleted all my music from my computer (I didnt think about backing it up), and while i was trying to do this i messed up my itunes and had to reinstall it. When i did this i lost all of

  • Grant execute on DBMS_CRYPTO package (11R1)

    I figured out I needed to grant my user access to this SYS package using: SQL> grant execute on DBMS_CRYPTO to lob_demo; Grant succeeded. yet after doing this, I still get this error: SQL> select DBMS_CRYPTO.HASH(bytes, DBMS_CRYPTO.HASH_SH1) from blo

  • A Simple problem I`m sure BUT ITS DRIViNG ME CRAAAZY!

    Hello, I hope someone can help. I published a site with the first podcst episode using iweb.It went through onto iTunes bo problem so all`s good... so today I put together the 2nd episode, submit it to itunes as before...up comes the `..please provid

  • Application Explorer - Not Loading To System Tray On Login

    Hi, We are getting users logging into their computers in the morning, and finding that the Novell Application Explorer is not loading into the Windows system tray. Manually running the program does not work, only a reboot seems to cure the issue. Any

  • RE: Looking for some database statistics and wait event statistics

    Hi: We are using Oracle 10g RAC on Sun Solaris 5.9. 1) In GV$SYSSTAT, we cannot find the following database statistics:      'global cache converts',      'global cache convert time',      'global cache gets',      'global cache get time',      'glob