class and component class

J

Jon Vaughan

Whats the difference between a class and a component class , they seem to
have identical structures, but different icons ?
and when would I use a component class over a a class ?

Thanks
 
H

Herfried K. Wagner [MVP]

Jon Vaughan said:
Whats the difference between a class and a component class , they seem to
have identical structures, but different icons ?
and when would I use a component class over a a class ?

Component classes inherit from 'System.ComponentModel.Component'. They can
be placed on forms, for example and are shown in the component tray at
design time.
 
M

Mythran

Herfried K. Wagner said:
Component classes inherit from 'System.ComponentModel.Component'. They
can be placed on forms, for example and are shown in the component tray at
design time.

An example of a component would be the OpenFileDialog and SaveFileDialog.
Both of these, as far as I can remember, are components. They are
associated with a form, but are not a user-interactable control located on
the parent form.

HTH,
Mythran
 
J

Jon Vaughan

When selecting a simple dist enterprise template , the data tier has a
default class that is a component class , why would this be ? is you arent
going to drop it on a form ?
 
H

Herfried K. Wagner [MVP]

Jon Vaughan said:
When selecting a simple dist enterprise template , the data tier has a
default class that is a component class , why would this be ? is you arent
going to drop it on a form ?

If it's shown in the designer's component tray, then yes, it's a component
class.
 

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

Similar Threads


Top