Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

3D Graph ActiveX on a MDI child Form in C#

Hi,

I was trying to write a MDI application in C#. There will be a 3D Graph ActiveX component on one of children forms. I did successfully run (in debug stage) the 3D graph on a standalone form, i.e. do not set the MDI parent property. However, when I set  "this.MdiParent" to the MDI form, and try to show this form,  it gives me an error message:

"Attempted to read or write protected memory. This is often an indication that other memory is corrupt." at the Application.Run(new frmMDI()); line in Program.cs.

at this stage, the program is already running and opened some other children forms.

If I comment out the "this.MdiParent = ..." line,  the form with 3D Graph shows up correctly.

I am using MS Visual studio 2005 and Measurement Studio 8.1. I wonder if this is a bug. Any body can provide solutions or the way get arround it.  Thank you in advance.

Best to you all.

Dufei
0 Kudos
Message 1 of 4
(5,240 Views)
Hi Dufei,

This was reported to R&D (# CAR 4CJ9BPZL) for further investigation. Thanks for the feedback!

Regards,
0 Kudos
Message 2 of 4
(5,221 Views)
Hi Dufei,

We are still investigating the issue. But we could find a workaround for the problem that you were facing. Instead of having the 3DGraph control directly on the child form, the control could be placed on a user control and this user control could be displayed on the child form. I have attached a sample application that does the same. Please let us know if this does not work for you.

Thanks
0 Kudos
Message 3 of 4
(5,135 Views)
thank you very much indeed. I will give it a try.

Dufei
0 Kudos
Message 4 of 4
(5,032 Views)