Constructors

Introduction:
  • Constructor is a member method of a class which is invoked automatically when an object to the class is created.
  • Constructor name should be same as the name of the class name.
  • Constructor is used to initialize values in to the data fields of the class or to pass required values in to the data fields.
Types of Constructors:
  • Default Constructor
    •  Default Constructor
    •  User Defined Defined Constructor
  • Parameterized  Constructor
  • Copy Constructor

Developing first ASP.NET web site

Strat[menu]-> Run-> devenv -> opens Visual studio if installed
then,
File[menu]-> New-> Website-> select visual C# or visual basic(VB) from the installed templates-> select ASP.NET Empty website ->web location-> name -> click on OK


 Web location:

ASP.NET Programming model

ASP.NET supports two types of programming models

Call Back Method:(Default)

If used then the data will be submitted automatically back to same page.

Page.IsPostBack: