……………………………………………….Expertise in .NET Technologies

  • Categories

  • Advertisements

Inline code and Code-Behind models

Posted by Ravi Varma Thumati on April 23, 2009

Code-Inline model in Asp.Net

In Code-Inline model the code & event handlers for the controls are located in <script> blocks in the same .aspx file that contains the HTML and controls. Code-Inline model is useful when you want to maintain your code and presentation logic in a single file.

Code-behind model in Asp.Net

ASP.NET also supports another way to factor your code and presentation content, called the code-behind model. When using code-behind, the code for handling events is located in a physically separate file from the page that contains server controls and markup. This clear delineation between code and content is useful when you need to maintain these separately, such as when more than one person is involved in creating the application. It is often common in group projects to have designers working on the UI portions of an application while developers work on the behavior or code. The code-behind model is well-suited to that environment.




Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: