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

Interop question

Thread ID:





93541 Mar 18,2010 08:08 PM UTC Mar 26,2010 03:56 AM UTC WinForms 3
Tags: GridControl
Administrator [Syncfusion]
Asked On March 18, 2010 08:08 PM UTC

I am using the grid control on a form VS2008 that I make into an Interop Control for VB6. The top level events like adding controls to the cell types, and any event handlers that I program fire just fine(I have a right mouse click event that fires a drop down menu and everything works.

The problem is when a rich text editor is launched by clicking the button(another working event) it launches, and the cancel button closes the control(another working event), but the save button does not write the value back to the cell, and opening the editor again the typed text is not present. The same thing happens for a calendar control on the grid. I am able to change months, years, and when a date is selected the calendar control closes, but the value is not written to the cell. A calendar control off of the grid works wonderfully, it is just the inherent cell type control event args I cant get to bubble up.

All of this works fine inside my test container when I am developing, but adding the control to the VB.6 form and running it loses those built in events in the control. Has anyone done any interop work or testing on this control? Do I need to write my own custom events and overide the internal ones? Does anyone have any idea how to do this? I am so close to getting this to do what I need it to it is sickening if I have to find another solution.

On an interop note I have referenced both the control, and added the reference to the .tlb in the project.


Administrator [Syncfusion]
Replied On March 18, 2010 09:47 PM UTC

Is the essential grid a C# assembly? So this would apply, so I would need to add additional wrappers to my project?

"To be specific, the VB compiler creates additional code in IL to make a VB class's events and properties visible in VB6, while the C# compiler does not. I had written the original templates with the assumption that the two compilers would write similar IL -- because of this faulty assumption, the events thrown in a C# UserControl were never received in VB6. This has been corrected in the updated C# templates by including in C# the extra attributes and interfaces required to make the events visible -- interfaces which the VB compiler automatically creates for you in IL."

Could this be the reason the save events are not firing for the grid cell controls?

Administrator [Syncfusion]
Replied On March 19, 2010 07:42 PM UTC

Going to stand alone .Net exe so never mind. :-D

Rajadurai C [Syncfusion]
Replied On March 26, 2010 03:56 AM UTC

Hi George,

Thanks for your update.



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