Nigel Whitworth's Development Site

You are currently not logged in.

ASP.NET Basics

ASP.NET is Microsofts new Internet Scripting technology. It's a shift away from when you could write a page on a non-professional operating system such as Windows 95, 98, Me and XP Home Edition to one that requires the top of the range equipment. It a merge of the new and old technologies, if you understand the old technology, then you should have no problems with this. Whilst you are able to design applications using ASP.NET Matrix or Visual Studio.NET, these pages are going to use the age old trusted Notepad method so you can understand how things are put together. HTML is still the same old HTML as it used to be. Code is no longer identified in the code by the <% and %> identifiers but by < script runat="server" > blocks. You must not forget the runat=server or the code will not be interpreted by the compiler. That also another change from ASP which used to be interpreted, ASP.NET is now compiled. Below is a simple ASP.NET
<HTML>
<script language="VB" runat="server">

    sub Page_Load(sender as object, e as eventargs)
        Message.text = "Hello"
    end sub

</script>

<Body>
    <asp:label id="Message" runat=server/>
</Body>
</HTML>
When you run the program, all that will be displayed will the message Hello. In the original ASP, lines of code were executed from the top down. Now with ASP.NET, the order of the execution is dealt with by events like a VB program. The Page_Load will act in the same way as Form_Load does in a VB program. That's where you can put in all the dynamic loads for the page such as datagrids which has its own section later.

As you will have noticed the <asp:label > line, this is a new feature of the scripting engine that will enable the compiler to treat the items as an object to be amended. Controls created the ASP: method will be converted to HTML and be accessible from any web browser. A combo box can be coded as :-

<Body>
    <asp:label id="Message" runat=server/>
</Body>




If you intend to vote or make a comment, please enter the security code. CODE

Make a comment

*Comments are the views of individuals, they may or may not be correct.
All comments are reviewed and accepted or rejected.
If you give an email address, you will be sent an email when someone makes a comment on this page.*

Name :
Email :
Comments :


Only name and Code is compulsory.