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

MouseLeftButtonDown and ClickCount

4 Answers 75 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Chris Greening
Top achievements
Rank 1
Chris Greening asked on 27 Apr 2010, 11:57 AM
When using the MouseLeftButtonDown event as created by VS 2010, using Silverlight 4 and latest version of Telerik components:

private
void grdCases_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)

 

{

 

 

 

//if (e.ClickCount >= 2)
// localViewModel.GrdCasesDoubleLeftClickCommand.Execute(null);

 

 

}


e.ClickCount is not available.

Having read previous posts I changed MouseButtonEventArgs to

Telerik.Windows.Input.

 

MouseButtonEventArgs 

 

 

and when I run the application and access the page I get:

System.Windows.Markup.XamlParseException occurred
  Message=Failed to assign to property 'System.Windows.UIElement.MouseLeftButtonDown'. [Line: 43 Position: 192]
  LineNumber=43
  LinePosition=192
  StackTrace:
       at System.Windows.Application.LoadComponent(Object component, Uri resourceLocator)
       at Northgate.Platinum.Modules.Cases.Views.CaseListView.InitializeComponent()
       at Northgate.Platinum.Modules.Cases.Views.CaseListView..ctor(CaseListViewModel viewModel)
  InnerException: System.IO.FileLoadException
       Message=Could not load file or assembly 'System.Windows.Controls.Toolkit, Version=4.0.5.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The requested assembly version conflicts with what is already bound in the app domain or specified in the manifest. (Exception from HRESULT: 0x80131053)
       StackTrace:
            at System.Reflection.RuntimeAssembly.nLoadImage(Byte[] rawAssembly, Byte[] rawSymbolStore, Evidence evidence, StackCrawlMark& stackMark, Boolean fIntrospection, SecurityContextSource securityContextSource)
            at System.Reflection.Assembly.Load(Byte[] rawAssembly)
            at MS.Internal.JoltHelper.LoadAssembly(Byte[] buffdata, Assembly& loadedAssembly)
       InnerException:


Any help would be appreciated

4 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 27 Apr 2010, 12:01 PM
Hi,

I'm not sure how System.Windows.Controls.Toolkit is related to RadGridView - can you provide more info?

Best wishes,
Vlad
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.
0
Chris Greening
Top achievements
Rank 1
answered on 27 Apr 2010, 12:48 PM
not sure myself but I followed the example provided here:

http://blogs.telerik.com/valerihristov/posts/09-05-20/mouse_right_click_double_click_and_mouse_wheel_in_radcontrols_for_silverlight.aspx

all I did was change the MouseButtonEventArgs to Telerik.Windows.Input.MouseButtonEventArgs 
0
Vlad
Telerik team
answered on 27 Apr 2010, 01:02 PM
Hello,

Our events demonstrated in this blog post cannot be attached in XAML - in your case you've used the original Silverlight event however you have changed the event handler signature and that is why you have such problems. Alternatively  I can suggest you to check this demo - may help you in your scenario.

Regards,
Vlad
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.
0
Chris Greening
Top achievements
Rank 1
answered on 27 Apr 2010, 01:28 PM
thanks for pointing me at the demo, this has now solved my problem
Tags
GridView
Asked by
Chris Greening
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Chris Greening
Top achievements
Rank 1
Share this question
or