Reputation: 6083
i want to know that why we use code behid approch. if there is some advantage then plese share to me ? as we know that there is two methode for writing server side code for aspx.file
so i wnat to know that is ther any authentic reasion which provide advatage in code-behind approch.
Upvotes: 3
Views: 1212
Reputation: 61727
It helps prevent spaghetti code with a mix of markup and code, which is hard to maintain and review.
Upvotes: 0
Reputation: 55489
You should strive to separate UI layout from UI or business logic. Those who use codebehind benefit from the advantages of compile-time warnings, type safety, and better debugging support.
Check this article - https://web.archive.org/web/1/http://articles.techrepublic%2ecom%2ecom/5100-10878_11-1049844.html
EDITED: this one is helpful too to give information of code-behind pages - http://www.java-samples.com/showtutorial.php?tutorialid=1084
Upvotes: 2