Two Visual Studio 2008 Tips ASP.NET Tutorial
Uploader Comments (bidwx)
All Comments (7)
-
I am kinda new in the .net scene and ill be watching more but whatsup with the cursor it looks mad.
-
You say not to put business logic in your page itself, but then you contradict it by creating an instance of a class within your button's click event, instead of creating the instance as a property of the form or making this method static, which is also more business logic then the creation of a string, which in my opinion, is part of the designers work who you would now have to share your Greeter Class in order to be able to change that.
These tricks should only be done in big programs.
-
I realize this is an old thread but I found this to be quite useful -- thanks, bidwx. To answer exlova's question, it's bad form to embed business logic such as "Hello world" in the codebehind. Typically, if a future developer wanted to change this greeting, the appropriate place to look would be in the construct behind the button's instance, which is what he is demonstrating here.
-
Where do I download this software please?



Why do you want to avoid business logic?
exlova 1 year ago
Hi - In order to improve the ability to maintain, change, and extend the code, business logic should not be combined with the user interface code. Check out our videos on UML for a discussion on how to break an application into classes.
bidwx 1 year ago