Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

MenuItemExecute("Annots:TextEditMenu:HighlightSel") is not working

New Here ,
Jan 05, 2017 Jan 05, 2017

Hello,

I am using IAC OLE automation APIs for inter-application communication with PDF document.

I want to execute "Highlight text" menu item programmatically using MenuItemExecute("Annots:TextEditMenu:HighlightSel"), however its not working.

I checked whether this menu item is enabled or not using MenuItemIsEnabled("Annots:TextEditMenu:HighlightSel").

Its returning -1. And as per documentation(http://help.adobe.com/en_US/acrobat/acrobat_dc_sdk/2015/HTMLHelp/#t=Acro12_MasterBook%2FIAC_API_OLE_...), It means that menu is enabled.

However, whenever I execute the function MenuItemExecute("Annots:TextEditMenu:HighlightSel"), It gives me following error:

"Attempt to call a method that has not been implemented"

I am putting my code snippet here:

CAcroApp *m_pAcroApp;

COleException e;

m_pAcroApp = new CAcroApp;

m_pAcroApp->CreateDispatch("AcroExch.App", &e);

m_pAcroApp->MenuItemExecute("Annots:TextEditMenu:HighlightSel");

Product details that I am using are:

Acrobat version : Acrobat Pro DC (Classic-Acrobat2015)

SDK: Acrobat DC SDK

Operating system: Windows 7

IDE: Microsoft Visual studio 2013

Please help.

Thank you in advance!

Regards,

Navnath.

TOPICS
Acrobat SDK and JavaScript
2.0K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jan 06, 2017 Jan 06, 2017

If I remember correctly, this was a valid menu item to execute back in Acrobat 9 - before the user interface was dramatically changed in Acrobat X and then again in DC. There is no such menu item anymore in Acrobat DC. You can list the names of all menu items using the JavaScript app.listMenuItems() method (see here for more information: Acrobat DC SDK Documentation - app.listMenuItems()

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jan 08, 2017 Jan 08, 2017
LATEST

It works in Acrobat XI...

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines