Yes, what you suggested is the right idea. However, something quirky is going on. Not surprising because this whole SDK is quirky. When I use the code as you show.
or
it works very well. However, when used with the AcroPDTextSelect method (below) I get all types of errors. The document makes it clear on this page (131) that the text result needs to be output in some type of loop. But I can even get basic results to fire.
Thanks
;/exe 1
typelib Acrobat {78165D71-DF28-11d3-9A89-005004A56D53} 1.0
Acrobat.AcroApp app._create
Acrobat.AcroAVDoc avdoc=app.GetActiveDoc()
str myt = avdoc.GetTitle()
out myt
;/exe 1
typelib Acrobat {78165D71-DF28-11d3-9A89-005004A56D53} 1.0
Acrobat.AcroApp app._create
Acrobat.AcroAVDoc avdoc=app.GetActiveDoc()
avdoc.FindText("long", 0, 0, 0)
Thanks