Q: Inheriting forms

  • Thread starter Thread starter Visual Systems AB \(Martin Arvidsson\)
  • Start date Start date
V

Visual Systems AB \(Martin Arvidsson\)

Hi!

I have created a form called "TheBase" on that form i have a ListControl.
The listcontrol is set to Protected.

Now i have created a new form called InheritedForm like this

public class InheritedForm : TheBase
{
....
}

All the components and so on are inherited from TheBase, but what i want to
do is to
add extra columns to the ListControl, but this property is readonly. Is
there any way to go round this?

I want all the methods and so on from TheBase but want to add extra
functionallity to InheritedForm and the ListControl.

Regards

Martin Arvidsson
 
Hello,

You can add your columns from your InheritedForm using
listView1.Columns.Add( "MyColumn", 200, HorizontalAlignment.Left );
 
Back
Top