Warning about an abstract class

D

Dom

I am building a fairly complicated program in the MS Visual Studio.
When it builds I get a warning:

"The designer must create an instance of type 'CardCatalogue.CCGrid'
but it cannot because the type is declared as abstract."

CCGrid is declared this way: "abstract public partial class
CCGrid : Grid"
and Grid is declared this way: "public partial class Grid :
DataGridView"

The program builds and runs fine, but it still worries me. How do I
handle this?

Dom
 
D

Dom

How do you want to handle it?

The warning is clear, given the code you're describing.  If you don't care  
that the Designer can't create an instance of your abstract class, then  
just leave it as is.  If you need for the Designer to be able to createan  
instance, you can't make your class abstract.

Take your pick.

Pete

Thanks, Pete: I thought it was a warning in the sense that better
programming design was needed. In point of fact, though, I don't need
to instance CCGrid, I only inherit it in other classes that are not
abstract.

Dom
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top