J
Jen
Hi,
I have several custom controls that all work correctly when placed on a form
and appear on the toolbox. The problem that I'm seeing is that 2 of the 5
controls disable form inheritance when placed on the base form. If I remove
both of these controls from the base form then my form inheritance works
again and I can see the other controls on the form.
I get the error "Visual inheritance is currently disabled because the base
class references a device-specific component or contains p/invoke" on the
non-base forms at design time.
I have checked and neither of the controls uses p/invoke.
What would a device specific component be? The SIP control? I remarked it
out.
What other things could cause this?
Anyone care to see the code?
These are some of the references.
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
using System.Threading;
using Microsoft.WindowsCE.Forms;
using System.Diagnostics;
I also have a reference to "System.Windows.Forms.DataGrid" in the solution
explorer
However i cant add "using System.Windows.Forms.DataGrid" cause i get the
error that it is a type not a namespace.
These 2 controls are the only ones that have a reference to the datagrid
(possible clue)
So if I have a custom control that refers to the datagrid does this kill
form inheritance?
Thanks
I have several custom controls that all work correctly when placed on a form
and appear on the toolbox. The problem that I'm seeing is that 2 of the 5
controls disable form inheritance when placed on the base form. If I remove
both of these controls from the base form then my form inheritance works
again and I can see the other controls on the form.
I get the error "Visual inheritance is currently disabled because the base
class references a device-specific component or contains p/invoke" on the
non-base forms at design time.
I have checked and neither of the controls uses p/invoke.
What would a device specific component be? The SIP control? I remarked it
out.
What other things could cause this?
Anyone care to see the code?
These are some of the references.
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
using System.Threading;
using Microsoft.WindowsCE.Forms;
using System.Diagnostics;
I also have a reference to "System.Windows.Forms.DataGrid" in the solution
explorer
However i cant add "using System.Windows.Forms.DataGrid" cause i get the
error that it is a type not a namespace.
These 2 controls are the only ones that have a reference to the datagrid
(possible clue)
So if I have a custom control that refers to the datagrid does this kill
form inheritance?
Thanks