Disable right-click menu in PdfViewer?

2 Answers 8 Views
PdfViewer and PdfViewerNavigator
Kao Hung
Top achievements
Rank 1
Iron
Kao Hung asked on 01 Aug 2025, 01:46 AM

Disable right-click menu in PdfViewer?

2 Answers, 1 is accepted

Sort by
0
Accepted
Dinko | Tech Support Engineer
Telerik team
answered on 01 Aug 2025, 10:28 AM

Hello Kao Hung,

To disable the right-click context menu in RadPdfViewer, you can set the RadContextMenu property to null. This will completely remove the context menu and prevent it from appearing when the user right-clicks inside the RadPdfViewer. Here is how you can do this:

this.radPdfViewer1.RadContextMenu = null;

Regards,
Dinko | Tech Support Engineer
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Kao Hung
Top achievements
Rank 1
Iron
commented on 05 Aug 2025, 12:04 AM

radPdfViewer1.PdfViewerElement.ContextMenu = null; // 隱藏radPdfViewer1滑鼠右鍵項目
0
Kao Hung
Top achievements
Rank 1
Iron
answered on 05 Aug 2025, 12:07 AM | edited on 05 Aug 2025, 12:11 AM

Share other features分享其他功能

隱藏radPdfViewer1滑鼠右鍵列印專案
foreach (RadItem item in this.radPdfViewer1.PdfViewerElement.ContextMenu.Items)
{
if (item.Text.Contains(“P&rint”))
{
專案。可見性 = ElementVisibility.Collapsed;
Debug.WriteLine(“右鍵選單內容: ” + item.文本);

                }

            }

Dinko | Tech Support Engineer
Telerik team
commented on 05 Aug 2025, 08:34 AM

I have correctly translated your post, you are sharing a way to hide a specific item. Thank you for sharing it with the community. For more information on how to add a new item, for example, please check the RadPdfViewer - Context Menu help article.
Tags
PdfViewer and PdfViewerNavigator
Asked by
Kao Hung
Top achievements
Rank 1
Iron
Answers by
Dinko | Tech Support Engineer
Telerik team
Kao Hung
Top achievements
Rank 1
Iron
Share this question
or