Visual inheritance & DESIGNER constant: Where is it?
From: Strider (Strider_at_discussions.microsoft.com)
Date: 10/14/04
- Next message: Strider: "Visual inheritance and DESIGN constant: Where is it?"
- Previous message: Otto Atzwanger: "Datagrid"
- Next in thread: Strider: "RE: Visual inheritance & DESIGNER constant: Where is it?"
- Reply: Strider: "RE: Visual inheritance & DESIGNER constant: Where is it?"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 14 Oct 2004 03:27:03 -0700
Hello all!
I have developed a class that inherits from System.Windows.Forms.Form which
enhances the base type's keyboard handling.
This new type (EnhancedForm) is to be inherited from all the forms in my
project.
I am aware that visual inheritance is not supported in the CF, so I tried to
fool the designer by declaring my subclasses like this:
#if DESIGN
public class ASubclassedForm: System.Windows.Forms.Form
#else
public class ASubclassedForm: MyCompany.Windows.Forms.EnhancedForm
#
{
...
Visual studio .NET 2003 is supposed to automatically define a constant named
"DESIGN" in design time. I've seen it used in OpenNetCF and read articles
about it, but in my case the code under the #if DESIGN block is allways
grayed out in the designer, unless I define the constant myself.
Any clues?
Thanks in advance.
- Next message: Strider: "Visual inheritance and DESIGN constant: Where is it?"
- Previous message: Otto Atzwanger: "Datagrid"
- Next in thread: Strider: "RE: Visual inheritance & DESIGNER constant: Where is it?"
- Reply: Strider: "RE: Visual inheritance & DESIGNER constant: Where is it?"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|