RE: ASP vs ASP.NET

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: Cowboy (Gregory A. Beamer) - MVP (NoSpamMgbworld_at_comcast.netNoSpamM)
Date: 11/22/04


Date: Mon, 22 Nov 2004 10:55:36 -0800

Overall, ASP uses a looping methodology, while ASP.NET uses a binding
methodology. Once you make the mental shift necessary to understand it, you
find it far more beautiful than ASP as you have a true separation of tags and
code (UI versus dynamic code by your vernacular).

The 3 guys article is likely to be an early article where the code was not
placed in CodeBehind. Thus, it looks messier. Once you learn to bind, it
comes down to the following example:

<% Do until objRS.EOF %>
<tr>
<td>
<%=objRS(0)%>
</td>
</tr>
<% Loop %>

etc.

versus

<asp:DataGrid id="DataGrid1" %>

In codeBehind

DataGrid1.DataSource = objDataReader

The first example is far messier and more likely to get munged up by your
FrontPage artist than the second.

Just my two cents, but all of the "ASP is better" arguments I have seen rely
on bad examples in ASP.NET (moving ASP methodology into ASP.NET code world).

---
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA
***************************
Think Outside the Box!
***************************
"Nathan Sokalski" wrote:
> I was recently looking at a page about transitioning from ASP 3.0 to 
> ASP.NET. (The page I was looking at is located at 
> http://www.4guysfromrolla.com/webtech/041601-1.shtml ). It looks to me like 
> they are taking away what has always seemed to me like the beauty of ASP. I 
> always viewed the beauty of ASP as giving you the ability to fill in the 
> dynamic areas without the need to change your HTML layout techniques. But 
> ASP.NET seems to be trying to make you replace all HTML elements with 
> ASP.NET code. For example, on the page I mentioned, notice how ASP.NET code 
> is used to create the submit button even though the submit button does not 
> have any dynamic areas. Also, when initially designing a page, I have always 
> preferred to create it with HTML to make it look the way I want and then 
> replace the dynamic areas with ASP. And just out of curiosity, for anyone 
> who might know, will the "View Source" look the same? Because this is one of 
> the primary tools to make sure the code is producing what I want, I need 
> this to look the same as it would using ASP. Does anyone else have an 
> opinion on whether ASP.NET is really better? Even though I have not yet 
> learned much about coding in ASP.NET, what I have seen makes me lean towards 
> ASP 3.0.
> -- 
> Nathan Sokalski
> njsokalski@hotmail.com
> www.nathansokalski.com 
> 
> 
> 

Quantcast