We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Unable to cast ...... XPMenusProvider to IContextMenuProvider

Thread ID:





95123 Jun 22,2010 10:00 AM UTC Jan 31,2014 05:16 PM UTC WinForms 5
Tags: GridControl
Richard Jacobs
Asked On June 22, 2010 10:00 AM UTC


I have been trying to use your PivotGridControl in our application.

I tested this was fit for purpose by creating a little app to test it would work and all seemed great.

I then tried to incorporate my test app in to our application and now each time I try to DataBind the grid to a datasource I get the error:

"Unable to cast object of type 'Syncfusion.Windows.Forms.Tools.XPMenus.XPMenusProvider' to type 'Syncfusion.Windows.Forms.IContextMenuProvider'."

The application is .NET 2.0 and the the new project I added in is also .NET 2.0

Please can you help

Much appreciated

Nirmal Raja [Syncfusion]
Replied On June 23, 2010 02:54 PM UTC

Hi Richard,

Thank you for your interest in Syncfusion products.

The IContextMenu interface and the XPMenu component has be conflicted due to the reference missing. The XPMenu is on Tools.Windows and the provided interface is in the Shared.Base. You would have missed any only of the assembly in the references of both pivot and the application. Try by attaching both the assembly of Syncfusion.Tools.Windows and Syncfusion.Shared.Base to the references.

Let me know if you still face any issues.


JD West
Replied On June 24, 2010 09:20 PM UTC

I am having the exact same issue.

It seemed to be working last time I was in this project, and have not run any syncfusion updates.

Not sure if it matters, but I did do my "normal" system updates this week though.

Please help!!!


JD West
Replied On June 24, 2010 09:24 PM UTC

UPDATE: It seems to be working now.

Not sure if this did it, but I exited the VS2010 IDE, reran the "Syncfusion Dashboard", chose the MultiTargetManager, and set my Target to 2.0.

Then reopened the IDE, seems to work.

Nirmal Raja [Syncfusion]
Replied On June 25, 2010 10:59 AM UTC

Hi JD,

We are glad to hear that the issue has been resolved on your end. As we specified in the previous update, this issue is depends on the mismatch in the version of the assemblies. The target manager will point out to single framework assembly which seems to fix the issue.


Adam Bruss
Replied On January 31, 2014 05:16 PM UTC

We are getting the same error. We have two syncfusion projects in Visual Studio. One is VS 2008 and needs to use the .NET 3.5 and the other in VS 2012 and needs to use .NET 4.0. How can we get both to work on the same development machine? Setting the .NET framework in Multi-Target Manager has no effect. The only thing that works right now is removing the .net 3.5 or 4.0 assemblies in the Assembly Manager to get the respective project to work. Is there an easier way?  



This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon