Bug with function bookmrk.GetByTitle. It stoped working as it should on Windows 7
function bookmrk.GetByTitle stoped working as it should. It worked properly early. We tried to reinstall then Acrobat, but it didn't help.
Windows 7. Acrobat Pro DC 2021.007.20102
Error in the following VBScript:
Set MainPartDocument = CreateObject("AcroExch.PDDoc")
Set bookmrk = CreateObject("AcroExch.PDBookmark")
'on the next line function returns False, although the "bookmark" exists in the file. GetByTitle actually can't get the bookmark.
res = bookmrk.GetByTitle(MainPartDocument, "bookmark")
if res then
msgbox "bookmrk exists " & bookmrk.GetTitle
It looks like a bug. The problem was solved by installing Acrobat Reader on the PC additionally to Acrobat Pro. We noticed, that the problem reproduced only on PC's with Pro version only.