Is there an alternative to Delphi ActionManager in Visual Studio

I am relatively new to VS and C #, but have many years of experience with Delphi. One of my favorite components when developing a graphical interface in Delphi is the ActionManager, a centralized way to assign event handlers to actions, as well as turn them on / off. Surprisingly, I cannot find anything like it in Visual Studio 2008 Professional. I am sure that there should be third-party implementations, but I would prefer something standard.

Can someone suggest me something for this? Maybe there is an alternative way to effectively manage the actions of the GUI that I am missing?

+6
c # visual-studio delphi winforms tactionmanager
source share
2 answers

WPF has Teams that are conceptually similar.

+3
source share

I also loved ActionManager. At that time I did not know about it, but all this is a fantastic implementation of Model-View-Controller. Looking back, Delphi was too advanced for the unprepared developer community 8 -)

Back to your question, in C # there is a concept of events and delegates that are equivalent to actions and their handlers. You associate control events (or GUI actions) with delegates. For example,

mybutton.Click += HandleMyButtonClick; 

Click will be a void (object sender, EventArgs e) delegate void (object sender, EventArgs e) . This signature will be followed by the HandleMyButtonClick method, like this.

 void HandleMyButtonClick(object sender, EventArgs e) 

The documentation for the class controls will have a section listing all the events that were raised. These events will also describe the signature of delegates required to process them.

+1
source share

All Articles