This is a migrated thread and some comments may be shown as answers.

[Solved] How to open a RadContextMenu using AutomationPeer?

2 Answers 97 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Kori
Top achievements
Rank 1
Kori asked on 19 Jun 2009, 04:55 PM
Hi,

I'm trying to use a RadContextMenuAutomationPeer to open a RadContextMenu, but I can't seem to get it to work.  Since there are no Providers on the RadContextMenuAutomationPeer class, I've tried using AutomationPeer.RaiseAutomationEvent(AutomationEvents.MenuOpened) and AutomationPeer.RaiseAutomationEvent(AutomationEvents.ToolTipOpened), but neither seem to work. 

Right now I'm using the workaround of calling RadMenuItemAutomationPeer.Invoke() directly without opening the menu first, but I'd like to better match what the user would actually be doing. 

Is there a way to open the context menu for UI automation?

Thanks,
Kori

2 Answers, 1 is accepted

Sort by
0
Accepted
Valeri Hristov
Telerik team
answered on 22 Jun 2009, 02:00 PM
Hi Kori,

Unfortunately the current version (Q2 2009 SP2) of the AutomationPeer of RadContextMenu do not support opening the control. I implemented IExpandCollapseProvider that will allow you to Show/Hide the context menu and the upcoming internal build this friday will contain the updated assemblies. If you need this feature earlier, please, open a new support ticket and I will send you the binaries.

Your points have been updated.

Greetings,
Valeri Hristov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Kori
Top achievements
Rank 1
answered on 02 Jul 2009, 09:27 PM
Thanks, I look forward to using the new version!
Tags
GridView
Asked by
Kori
Top achievements
Rank 1
Answers by
Valeri Hristov
Telerik team
Kori
Top achievements
Rank 1
Share this question
or