My question is regarding implementing MVC pattern in winforms
I learned that the controller object is responsible for handling the events raised in the view. Can any one please tell me how can the controller reacts to the text input or button press event in the view? I mean how can the controller know that some event happened without it being handled in the view as these controls(textbox,button) are private to view.
The idea is that the view catches the event and then call on an appropriate function in the controller. In Windows Forms that means that you’ll attach an event handler for e.g. “button_click”, which then call on controller.doFoo().
You might be interessted in reading GUI Architectures at Martin Fowlers site.