Sunteți pe pagina 1din 4

Project Structure Asp.

net using C#-


1.Solution Explorer
-Solution Explorer is Collection Web Projects or NameSpaces.
2.Projet(webApplication)/NameSpace(ConnsoleProgram)
-Project Collection of WebPages and Collection classes
3.WebPage/class
-Collection of Items

Console Programming of C#-


Class-
-Collection items
ex- methods,constructores,Destructors,Variables
Class Contain Three types Things-
1.Class Variable
2.Reference Of Class
3.Class Object

1.Variable of class-
a copy of the class that is not initialized.
ex-ClassName cn;

2.Instance of class-
-a copy of the class that is initilized by using the new keyword.
-every instance is unique of itself
-the changes made of one instance will never reflect to another instance.
-instance class own memory and never shared with another
ex-ClassName cn=new ClassName(); //Instance of class
int x=50,y=100;
ClassName cn1=new ClassName();
Console.WriteLine(cn.x+" "+cn.y);
int x=100,y=200;
Console.WriteLine(cn1.x+" "+cn1.y);

3.Reference of The Class-


-a copy of the class that is initialized by using an existing instance.
-reference of class will not have any memory allocation they will be
-sharing the same memory of the instance that assigned
-for initializing the variable.
-variable can not be use calling the member-
-but reference can be use calling the member.
-references will not have own memory-
-reference is only a ponter to the instance.
ClassName cn1=new ClassName(); //cn is instance of class
ClassName cn2=cn1; //cn2 if reference of the class
Classname cn; //cn is Variable of the class

Access Specifiere-
private
public
protected
internal
protected internal

Access specifiers:
-it's special kind of modifiers
-using which we can define the scope of a type and it's members.
-if we don't mention any acess specifier then by default private

-that called by default private and we can not use private on a class
-if we don't make public then by default internal.

-C# support five access specifier


1.private
2.internal
-if we declared a member or class as internal,
-it's only access with in the project and-
-in the project child class as well as non-child class also can access
3.protected
-member declared protected in a class, always accesable only
-in the child class,not acessable from not child class.
4.protected internal
-if protected and internal any of these aceessable-
-then protected internal accessable
-if protected and internal any of these not accessable
-then protected internal not accessable.
5.public

Constructor
-it is special method present under a class responsible for initializing the
variable of that class.
-the name of a constructor method is exactly the same name of the class in
whichit was present.
-it's non-value returning method.
-each and every class requires this constructor if we want to create the instance
of that class.
-we can defind constructor explicitly and implicitly

Asp.net using C#-

Validation-
-validates the user input data to ensure that
useless,unauthonticated,or contradictory data don't get stored
-validation is the process of validating the
webform by submitting proper Up to the program
Two Types Of Validation-
-ClientSideValidation-
validate the webform at browser(using JavaScript)
-ServerSide Validation-
valdating webform at webserver(using c#,php,or server side programming lang)
*Valiadation Controls-
1.RequiredFieldValidator
-it is use to check emptiness of control
-properties:
1.ControlToValidate
2.ErrorMessage
2.RangeValidator
3.CompareValidator
4.RegularExpressionValidator
5.CustomValidator
*MasterPage-
- .master extension
- we can create one or more master pages in our project
- a master can have another masterPage as master
- if we want to create master page in our project-
-then we have to create firstly master page then after child pages
- we can transfer one master page onto another master page
- Controls of MasterPage can be programed in the mastePage and Content page
but, content page control will never be programed in mastePage.

- two tags use to in master page and child pages


1.ContentPlaceHolder
-this tag use in master page
-ContentPlaceHolder we are going to provide the content in .aspx page
2.Content
-this tag use in child pages of master page
-content tag use to Override content of the ContentPlaceHolder(in
MasterPage-)
-content page content can be placed only inside the content tag.

*Storing and Retriving Data With ADO.NET


-ADO.NET stands for Microsoft ActiveXData object
-ADO.net is an object model
-used to establish connection b/w application and data source
-Datasource cane be Database and XML
or
-ADO.NET is not a different technology,in simple terms,
-ADO.NET set of classes(framework),that can be used to intract with datasource
-like database and XML files
-this can,then be consumed in any .NET application.

-few different types of .net application that use ADO.net to connect to


database,execute,retrive data.
1.ASP.net web application
2.Windows Application
3.Console Application

-.Net Data Providers-


Data Provider for SQL server -System.Data.SqlClient
Data provider for Oracle -System.DataOracleClient
Data Provider for ODBC -System.Data.Odbc

-it consist of classess that can be used to connect,retrive and manipilate data.
- Two Main Components of ADO.net
1.Data Provider
2.Dataset
-1.Dataset

*Exception Handling
*Use Of Ajax On the Web Form
-Ajax Controls
-Using Ajax Controls on the web-Form

Project
-Database
-EntityRelationship Diagram(Data-Model)
-Web_Pages
-Database_Connectivity

S-ar putea să vă placă și