Slide 10.f: Adding simple code to a page (cont.)
Slide 10.h: ASP.NET programming
Home

Adding Simple Code to a Page (Cont.)


While <% %> code blocks provide a powerful way to custom manipulate the text output returned from an ASP.NET page, they do not provide a clean HTML programming model. As the previous sample illustrates, developers using only <% %> code blocks must custom manage page state between round trips and custom interpret posted values. The following list gives some comments about the program: The code illustrates a limitation in classic ASP: The code block has to be placed where you want the output to appear. With classic ASP it is impossible to separate executable code from the HTML itself. This makes the page difficult to read, and difficult to maintain.