M
Marcel Hug
Hi NG !
For learning work with patterns I would like to add the MVC-Pattern in my
little application.
On my form (View) I have a TabController with 2 tabs. In each tab I would
like to have a datagrid, which should be updated after some changes. So this
two datagrids must implement my observer-interface. My class supportControl
would be the Model, which extends from my observable class.
Thats my theoretical understanding...now my questions to the implementation
in C#:
1.) The 2 Datagrids are the objects, which must be updated. Do I have to
create two classes (for each datagris one), which extends from
System.Windows.Forms.DataGrid and implements my observer interface ?
2.) My DataGrid on the main form would initialized by the classes i created
under point 1.) ???
Sorry this questions, but I'm not sure, if thats the right way of
implementation MVC !
Thanks and regards
Marcel Hug
For learning work with patterns I would like to add the MVC-Pattern in my
little application.
On my form (View) I have a TabController with 2 tabs. In each tab I would
like to have a datagrid, which should be updated after some changes. So this
two datagrids must implement my observer-interface. My class supportControl
would be the Model, which extends from my observable class.
Thats my theoretical understanding...now my questions to the implementation
in C#:
1.) The 2 Datagrids are the objects, which must be updated. Do I have to
create two classes (for each datagris one), which extends from
System.Windows.Forms.DataGrid and implements my observer interface ?
2.) My DataGrid on the main form would initialized by the classes i created
under point 1.) ???
Sorry this questions, but I'm not sure, if thats the right way of
implementation MVC !
Thanks and regards
Marcel Hug