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

[Solved] Handling KeyDown+Click on UIElements

1 Answer 110 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Michele
Top achievements
Rank 2
Michele asked on 26 Oct 2010, 08:51 AM
Hello,
I need to handle sometimes the Keydown +click on MenuItems or TreeView Items in order to open in a new tab instad of in the current one.... I've looked a bit around and found this Extension that won't work with telerik's component .... can you please provide me a working extension?

Thanks

Paolo

1 Answer, 1 is accepted

Sort by
0
George
Telerik team
answered on 28 Oct 2010, 09:25 AM
Hi Paolo,

I will paste my answer in this topic as well. I hope everyone who needs similar functionality will find the asnwer here.

I would suggest you to use Keyboard.Modifiers property in order to get the pressed key. For example:

if ((Keyboard.Modifiers & ModifierKeys.Control) > 0)
{
    ...
}

For more information, please refer to the following link in msdn - http://msdn.microsoft.com/en-us/library/system.windows.input.keyboard.modifiers.aspx

Sincerely yours,
George
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
General Discussions
Asked by
Michele
Top achievements
Rank 2
Answers by
George
Telerik team
Share this question
or