W
W. Wandrey
Hallo,
I'm a newbie and try to learn C# while trying to progr. a
little game which in affect touches all aspects of the language:
syntax, arrays, painting, events .... so on events I be stuck:
is it possible (and how) to implement an OnClick-Event into a
class derived from :Object. i know it's easy to have it derived from
UserControls/Controls and higher Objects - but that seems for me
to have to much overhead for a simple Object.
Background:
Have a class that paints a rectangle on constructors call with some
other properties set. At least I need to have many of these rectangles.
Also any of them needs to have a OnClick to be identified an moved
at Click-event. How is this event to implement - anybody can give some
code-examples, please?
Regards
Willy
I'm a newbie and try to learn C# while trying to progr. a
little game which in affect touches all aspects of the language:
syntax, arrays, painting, events .... so on events I be stuck:
is it possible (and how) to implement an OnClick-Event into a
class derived from :Object. i know it's easy to have it derived from
UserControls/Controls and higher Objects - but that seems for me
to have to much overhead for a simple Object.
Background:
Have a class that paints a rectangle on constructors call with some
other properties set. At least I need to have many of these rectangles.
Also any of them needs to have a OnClick to be identified an moved
at Click-event. How is this event to implement - anybody can give some
code-examples, please?
Regards
Willy