Example of Context Menu in ASP.NET MVC PDF Viewer Control

Explore how to tailor context menus for PDF pages, annotations, and form fields in this sample.

DEMO
SOURCE
Properties
Hide Default Context Menu
Add Custom option at bottom

This customization empowers users to add new context menus on PDF pages, annotations, and form fields. In this sample:

  • Selecting text on pages reveals a custom context menu, enabling users to search for the selected text on Google.
  • Annotations and Form fields can be locked directly from the context menu.
  • Customization is achieved using the following APIs:
    • Customize the context menu by selectively displaying custom options, hiding existing menu items, controlled by boolean parameters in the addCustomMenu() method.
    • Position custom menu items either above or below existing ones, adjusting boolean parameters in the addCustomMenu() method.
    • Tailor the visibility of custom menu items using the customContextMenuBeforeOpen event.
    • Implement specific functionalities for custom options through the customContextMenuSelect event.

More information on the PDF Viewer instantiation can be found in this documentation sectionopens in a new tab.

Transform your ASP.NET MVC web apps today with Syncfusion® ASP.NET MVC components
100+ high-performance and responsive UI components
Dedicated support
Hassle-free licensing
TRY IT FOR FREE
opens in a new tab