SlideShare a Scribd company logo
JATIYA KABI KAZI NAZRUL ISLAM UNIVERSITY

Presentation On

Submitted to
Mr. Tushar Kanti Saha
Lecturer Deprt of CSE,
JKKNIU

Submitted By
Rasel khan
Roll: 11102027
Session: 2010-2011
Dept Of CSE
ASP.NET OVERVIEW
 Introduction & History
 Why use ASP.NET, Some characteristics & with Component
 Steps for developing a web based application and how to work
request with response.

 Working with ASP.NET MVC Framework.
 How to work HTTP Fundamentals.
 ASP.NET web application Routing.
 ASP.NET IIS & how to create virtual directory.
ASP.NET mean is Active Server Pages . It is a server-side Web
application framework designed for Web development to produce
dynamic Web pages .It was developed by Microsoft to allow
programmers to build ,

• Dynamic web sites,
• Web applications
• Web services
• The latest version of ASP is known as ASP.NET
• Visual Studio .NET is a developer application used to
create ASP.NET Web applications
• There are two main types of Web resources created
with ASP.NET applications
– Web Forms are ASP.NET pages within an ASP.NET
application
– Web Services are ASP.NET Web pages that contain
publicly exposed code so that other applications can
interact with them
– Web Services are identified with the file extension .asmx

Recommended for you

Online computer lab management system
Online computer lab management systemOnline computer lab management system
Online computer lab management system

This document summarizes a student project on a computer lab management system. The system was created to address issues with the existing manual lab management system. It allows both students and administrators to manage lab activities online. The system has modules for student and administrator functions. It uses Java and MySQL for the backend and HTML, CSS, and JavaScript for the frontend. Key features include secure login, viewing computer information, submitting assignments, and generating reports. The system aims to reduce paperwork and facilitate effective monitoring of student and staff activities in the computer lab.

online computer lab management system in java
java mini project for college students
java mini project for college students java mini project for college students
java mini project for college students

This document describes a 360 degree feedback web application created using Java. The application allows various stakeholders like customers, vendors, agents, and internal employees to provide feedback on an organization's services and support. It schedules feedback collection, stores ratings and comments in a database, and generates reports and dashboards to analyze feedback. The application was created using technologies like Java, JSP, Servlets, MySQL, HTML, and CSS. It has separate feedback forms and dashboards for students, teachers, and HR. Users can log in based on their role to provide feedback which is stored in a database. The application aims to help organizations improve their services based on feedback from various stakeholders.

javastudentcollege
TestingResume_3.6Yrs
TestingResume_3.6YrsTestingResume_3.6Yrs
TestingResume_3.6Yrs

Preeti Sharma is a software quality assurance engineer with over 3.5 years of experience in manual testing, automation testing, integration testing, and database testing. She has a Master's degree in Information Technology and has worked on projects involving .NET, Java, Salesforce, Oracle, and other technologies. Her technical skills include Selenium, SOAPUI, SQL, and she has experience writing test cases, developing test automation frameworks, and executing testing cycles.

ASP.NET 1.0 was released on January 5, 2002 as part of version
1.0 of the .NET Framework.
Scott Guthrie became the product unit manager for ASP.NET, and
development continued apace, with version 1.1 being released on
April 24, 2003 as a part of Windows Server 2003. This release
focused on improving ASP.NET's support for mobile devices.


Improved Performance and Scalability.



Compiled Execution, Rich Output Caching, Web Farm Session State.



Enhanced Reliability.



Memory Leak, Dead Lock, and Crash Protection



Easy Deployment.



No Touch" Application Deployment, Dynamic Update of Running Application,
Easy Migration Path



New Application Models.



XML Web Services



Developer Productivity.



Easy Programming Model, Flexible Language Options, Rich Class Framework.
 Code-behind model


It is recommended by Microsoft for dealing with dynamic program code to use the
code-behind model, which places this code in a separate file or in a specially designated
script tag

 User


controls

ASP.NET supports creating reusable components through the creation of User Controls

 Rendering technique


ASP.NET uses a visited composites rendering technique. During compilation, the
template (.aspx) file is compiled into initialization code which builds a control tree (the
composite) representing the original template
• Compiled code
 Code written in ASP.NET is compile and not interpreted.

• Enriched tool support
 ASP.NET applications using visual studio

• Power and flexibility
 ASP.NET applications are based on the CLR

• Simplicity
 ASP.NET enables you to build user interfaces that separate application logic from
presentation content

• Manageability
 ASP.NET provides a number of options in providing the above facilities

Recommended for you

Synopsis on online shopping by sudeep singh
Synopsis on online shopping by  sudeep singhSynopsis on online shopping by  sudeep singh
Synopsis on online shopping by sudeep singh

This document provides an overview of an online shopping project developed using Java. It discusses the aims of improving customer and vendor services. It maintains customer payment and product details. The key features are high accuracy, flexibility and easy availability. It uses database tables to represent entities and relationships. The project allows customers to shop online and buy items which are then shipped to the submitted address. It has modules for customers and stores.

Project report On MSM (Mobile Shop Management)
Project report On MSM (Mobile Shop Management)Project report On MSM (Mobile Shop Management)
Project report On MSM (Mobile Shop Management)

This document provides an overview of a proposed mobile store management system for Mahalakshmi Communications. Key points: - Mahalakshmi Communications is a mobile solution retailer with 2 stores and a vision to expand across India. - The proposed system will computerize manual processes like inventory, customer, and employee data to increase efficiency and data accuracy over the current paper-based system. - The system is designed to be easy to use, generate reports, and securely manage the store's data and operations through a database and user-friendly interface.

Manjeet aem
Manjeet aemManjeet aem
Manjeet aem

Manjeet Kumar is seeking assignments in software automation testing with reputable organizations. He has over 2 years of experience in software testing using Selenium, with skills in developing automation frameworks using ANT, JUnit, and generating reports. He has worked on projects involving CRM and billing software, developing test cases and automated test scripts to test functionality.

adobe cq 5.6
 Server control

Respond to users events by running event procedures on
the server.
 HTML control

Represent the standard visual elements provided in
HTML
 Data control

Provide a way to connect to perform commands on and
retrieve data from SQL , OL ,databases and XML data
files
 System components

Provide access to various system level events that occur
on the server
Step 1

–

Step 2
Step 3
Step 4
Step 5
Step 6
Step 7

–
–
–
–
–
–

Create Local Folders for Your Web
Project
Create a Blank Solution
Add a Web Site to Your Solution
Add a Class Library (Optional)
Check Your Solution Structure
Check Your Local Folder Structure
Add Your Solution to Source Control
Web Server

Web Browser

Get default.aspx

1. Client Initiates
2. Communications
With page request

Display page
Server response with
pages

1. Process request
2. Execute server slide
code
3. Store session data
4. Send result response
ASP.NET Presentation

Recommended for you

News portal
News portalNews portal
News portal

This document outlines an online news portal project that allows users to read updated news from various categories without login or payment. The system will be administered through a backend where authorized users can add, update, or delete news. The key objectives are to provide instant access to important news from different fields for people without time for newspapers. The system will have user registration, contact, search, and admin modules. Hardware and software requirements are specified for both the developer and user ends. Data flow diagrams and screen layouts are included to describe the system's design and interfaces.

online newsnews portalonline news portal system
mini_Project_SRS
mini_Project_SRSmini_Project_SRS
mini_Project_SRS

This document outlines the requirements for an online ordering web application. It will allow administrators to manage products and view orders, while clients can browse products and facilitate ordering. The application will use object-oriented programming concepts and model-view-controller architecture. It will require interfaces for administrator and client login, product management, order review, and the ordering process. Performance requirements include supporting multiple simultaneous users and displaying product quantities in real-time. Security measures like user authentication and access controls are also specified.

Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform
Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration PlatformMicrosoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform
Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform

Microsoft SharePoint 2013 is an Enterprise Collaboration Platform which offers a wide range of integrated solutions including Enterprise Content Management (ECM), Enterprise Social Networking, Business process management (BPM), Web Content Management (WCM), Business Intelligence (BI), Enterprise Search etc. Currently more than 80% of Fortune 500 companies are using Microsoft SharePoint solutions and the numbers are growing with the new Cloud Based SharePoint Online. Developers can use Cloud App Model and leverage familiar programming models and development tools to create custom solutions for Mobility, Social and Collaboration Search and Workflows.

sharepoint
ASP.NET Presentation
ASP.NET MVC
Model View Controller (MVC) applications by using the ASP.NET framework
WHAT IS ASP.NET MVC?

Saying simply, ASP.NET MVC is a new framework from Microsoft that sits over
standard ASP.NET engine.

ASP.NET MVC

ASP.NET
ASP.NET MVC Features

1. Clear separation of logic: Model, View, Controller
2. Test-Driven Development (TDD)
3. Full control over HTML and JavaScript
4. Friendly URLs

Recommended for you

Task tracking system
Task tracking systemTask tracking system
Task tracking system

This document describes a task tracking system created by four students for their class project. It provides an introduction to the system, which allows users and an admin to manage tasks and projects through a web interface. It outlines the system's objectives to improve productivity, communication, and profits. It also details the hardware and software requirements, implementation details for the admin and user modules, testing results, and future plans for additional features. The conclusion restates that task tracking facilitates communication between project collaborators.

Pulkit Sachdeva-Resume
Pulkit Sachdeva-ResumePulkit Sachdeva-Resume
Pulkit Sachdeva-Resume

Pulkit Sachdeva is a BMC Admin professional with over 2 years of experience working with Hindustan Times Media LTD. in New Delhi as a BMC Tools Administrator. He has knowledge and experience working with various BMC tools including Remedy AR System, TM ART, BPPM, ADDM, and BBCA. He is proficient in SQL, Oracle, Windows, Linux, and has experience writing test scripts using Silk Test Classic. Pulkit holds a Bachelor's degree in Computer Engineering and is seeking a position where he can make a meaningful contribution to an organization's success.

Zarafa Repair is Possible in Few Clicks
Zarafa Repair is Possible in Few ClicksZarafa Repair is Possible in Few Clicks
Zarafa Repair is Possible in Few Clicks

Zarafa mail repair tool recovers Zarafa mailboxes and databases from the Linux Server where Zafara server is installed. So, don't get panic after losing your emails stored in Zarafa mailbox.

zarafa repair
MODEL + VIEW + CONTROLLER = MVC
ASP.NET MVC provides an alternative to the ASP.NET “Web Forms” pattern for creating
MVC-based Web applications.

Views display the application's
user interface (UI). Typically,
this UI is created from the
model data.

Model objects implement the logic
for the application's data domain.
Often, model objects retrieve and
store the app state in a database.

Model

View

Controller

Controllers handle user
interaction, work with the
model, and select a view to
render that displays UI
Test-Driven Development (TDD)

Since the UI is completely separated from
the business logic, it’s now easy to write Unit
Tests for the ASP.NET MVC application.

Unit Tests that cover
User Actions and Data Model

User Interface

Controller

Data Objects
Full control over HTML & JS
In ASP.NET MVC, designed HTML & JS pages are not more messed up with
“postbacks” and “ViewStates”, which is specific for “Web-forms” pattern.

<input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE"
value="/wEPaA8FDzhjYjBhZjA0ODYyMTM2NBgGBR5fX0NvbnRyb2xzUmVxdWlyZVBvc3RCYWNr
S2V5X18WAQUhY3RsMDAkaGVhZGVyJHVjTWFpbk1lbnUkc2VhcmNoQnRuBTdjdGwwMCRNYWl
uQ29udGVudCRycHRWaWRlbyRjdGwwMyRwcmVzZW50YXRpb25DYXJkJG11bHRp" />
<script type="text/javascript">
//<![CDATA[
var theForm = document.forms['aspnetForm'];
function __doPostBack(eventTarget, eventArgument) {
if (!theForm.onsubmit || (theForm.onsubmit() != false)) {
theForm.__EVENTTARGET.value = eventTarget;
theForm.__EVENTARGUMENT.value = eventArgument;
theForm.submit();
}
}
//]]>
</script>
Friendly URLs
MVC binds web paths to the logical URLs rather
than to the physical files.
Physical location:

C:InetpubwwwrootWebSiteProducts.aspx

ASP.NET style:

http://www.website.com/Products.aspx?name=Me
at

MVC style:

http://www.website.com/Products/Meat

Recommended for you

Cv vipul valvi_java_developer
Cv vipul valvi_java_developerCv vipul valvi_java_developer
Cv vipul valvi_java_developer

Vipul Valvi has over 1 year of experience developing Java web applications using Spring MVC, Hibernate, and other frameworks. He has worked on projects such as an educational ERP system, question-answer forum, attendance management system, and more. His skills include Java, Spring, Hibernate, JavaScript, and MySQL. He is looking for a job as a software developer with a focus on back-end development.

javaspringspring mvc
A Software Engineering Project on Cyber cafe management
A Software Engineering Project on Cyber cafe managementA Software Engineering Project on Cyber cafe management
A Software Engineering Project on Cyber cafe management

Cyber Café Management is a complete package developed for management of systems in a cyber café. This project is intended to be used in a Cyber Café. All cyber cafes have some basic needs likeable to control the systems that are being rented to the customers and are charged on timely basis. The present project presented in:- 1. Use case diagram 2. Sequence diagram 3. Activity diagram 4. Class diagram

softwaresoftware developmentagile software development
Work experiences at Softcodeit
Work experiences at SoftcodeitWork experiences at Softcodeit
Work experiences at Softcodeit

H.V.Tamari worked on several projects at Softcodeit including: 1) Developing an online ordering web application using MVC architecture and MySQL database with features like user login, product display, ordering, and adding/deleting products. Issues included using PDO vs MySQL and routing/rendering problems. 2) Developing layouts for a Time Tracking Android app considering device dimensions and screen rotation, with challenges distinguishing Async tasks from AsyncAdapters. 3) Developing REST APIs for the mobile app using CakePHP including login, profiles, reports, tasks, with challenges getting JSON responses, database design, and parameter validation. 4) Modifying reports for an existing Time Tracking web app

HOW DOES ASP.NET MVC LOOKS LIKE?
ASP.NET MVC installs a new type of web project into VS2008.
A newly created project has an ASP.NET MVC
specific directory structure.
App_Data folder is the physical store for data.
Content folder keeps files such as scripts, CSS, images, and so on.
Controllers folder is the location for controllers. The MVC framework
requires the names of all controllers to end with "Controller"—for
example, HomeController, LoginController, or ProductController.
Models stores classes that handle application business logic.
Scripts folder is for script files that support the application. By default,
this folder contains AJAX script files and the JQuery library.

Views is the recommended location for views. Views use .aspx, .ascx,
and .master files, in addition to any other files that are related to
rendering views.
ASP.NET MVC supports pure MVC pattern, the same
development pattern Rails are based on. The advantages
of ASP.NET MVC applications:
1. It makes it easier to manage complexity by dividing an application into
the model, the view, and the controller.
2. It does not use view state or server-based forms.
3. It uses a Front Controller pattern that processes Web application
requests through a single controller. This enables you to design an
application that supports a rich routing infrastructure with friendly
URLs.
4. It provides better support for test-driven development (TDD).
5. It works well for Web applications that are supported by large teams
of developers and Web designers who need a high degree of control
over the application behavior.
 http://www.asp.net/mvc - official site
 http://weblogs.asp.net/scottgu/archive/2007/11/13/asp-net-mvcframework-part-1.aspx - development basics on ASP.NET MVC
 http://weblogs.asp.net/scottgu/archive/2007/12/03/asp-net-mvcframework-part-2-url-routing.aspx - URL routing used in ASP.NET MVC
 http://weblogs.asp.net/scottgu/archive/2007/12/06/asp-net-mvcframework-part-3-passing-viewdata-from-controllers-to-views.aspx interaction between Controllers and Views
 http://weblogs.asp.net/scottgu/archive/2007/12/09/asp-net-mvcframework-part-4-handling-form-edit-and-post-scenarios.aspx - managing
form input data

Recommended for you

Design & development of job portal system using joomla & its online reputatio...
Design & development of job portal system using joomla & its online reputatio...Design & development of job portal system using joomla & its online reputatio...
Design & development of job portal system using joomla & its online reputatio...

This Presentation is about the Design and Development of Job Portal System using the open source systems named Joomla and we have initiate the online activities for reputation of the website.

online reputation managementjob portal system developmentdigital marketing consultant
Goal setting
Goal settingGoal setting
Goal setting

This document contains goals for projects, mechanisms, and self-improvement. For projects, goals include completing customer sign-up features, migrating a service to the cloud, and creating learning modules. Mechanism goals focus on code reviews, building tools, and automating testing. Self-improvement goals are to work with product managers, learn new skills monthly, and mentor engineers. The document lists the impact, due date, and status for each goal.

Monitoring web application response times, a new approach
Monitoring web application response times, a new approachMonitoring web application response times, a new approach
Monitoring web application response times, a new approach

An approach to capturing and integrating web client Real User Measurements from the Navigation object with server-side network and HttpServer diagnostic events.

web application performance
ASP.NET Web API
and HTTP Fundamentals
CRAMMING YOUR BRAINS WITH
HTTP & ASP.NET WEB API
•

HTTP Fundamentals via Web API

•

Dependency Resolver

•

HTTP Messages

•

URIs

•

HTTP.SYS

•

Routing

•

IIS 101

•

Verbs

•

HTTP compression

•

Controllers and Actions

•

Persisted Connections

•

Status Codes

•

Web API Self Hosting

•

HttpRequestMessage
HttpResponseMessage

•

Error Handling

•

Content Negotiation

•

Media Type Formatters

•

OData

•

Validations

•

•

Hosting

More HTTP and Web API

•

Caching

•

Concurrency

•

Security

•

Streaming

•

WebSockets & SignalR
26
WHY IS HTTP IMPORTANT?
 HTTP is a first class application layer protocol
 Unlike other protocols it was created to support a single information

system
 That system happened to be the largest and main information
system of the human race:

27
NO REALLY, WHY?

Today's systems face new challenges:
 Broader reach of clients

Recommended for you

ASP.NET Best Practices - Useful Tips from the Trenches
ASP.NET Best Practices - Useful Tips from the TrenchesASP.NET Best Practices - Useful Tips from the Trenches
ASP.NET Best Practices - Useful Tips from the Trenches

This document outlines an ASP.NET best practices presentation, including an introduction to ASP.NET, demonstrations of best practices like using object browsers and handling page events, and tips on state management, exceptions, and AJAX. The target audience is programmers new to .NET development and existing ASP.NET developers. The presentation covers the ASP.NET page lifecycle, separation of concerns using multiple projects, and disabling viewstate where possible. Useful resources like MSDN and CodeProject are also listed.

aspnetmicrosoftweb development
Introduction to asp.net
Introduction to asp.netIntroduction to asp.net
Introduction to asp.net

This document provides an introduction and overview of ASP.NET, including what ASP.NET is, how it differs from ASP, ASP.NET files and how ASP.NET works. It describes the ASP.NET lifecycle and architecture. It also discusses ASP.NET page structure, development models including web forms and MVC, and provides examples of ASP.NET code. Key features and potential drawbacks of ASP.NET are summarized.

asp.net
Introduction to asp.net
Introduction to asp.netIntroduction to asp.net
Introduction to asp.net

The document provides an introduction to ASP.NET, including what ASP is, how ASP.NET builds on ASP, and the key benefits and components of ASP.NET. It discusses how ASP.NET web applications are executed via HTTP requests and responses, and how code is separated from presentation using code-behind files. It also summarizes the basic steps to create a simple ASP.NET application in Visual Studio.

asp.netshankmasp
What About ASP.NET Web API?
• The .NET platform never had a first
class framework for HTTP-based
services
• WCF was created as a SOAP-based
framework and never really
matured to support HTTP

29
THE HISTORY OF ASP.NET WEB API
6 Preview Versions

WCF Web API
on CodePlex

WCF WebHttp
Binding (.NET 4)

ASP.NET Web API 4
Release

ASP.NET is
Open Source

ASP.NET Web API 2
Release Candidate

ASP.NET Web API
(Beta)

30
HTTP Messages 101
 HTTP is a first class application protocol:
 Widely supported across platforms and devices

 Scalable
 Simple

 Uses the request-response messaging
pattern
 Define resource-based semantics and not
RPC (Remote Procedure Call) or methods
31
HTTP REQUEST MESSAGES
GET http://localhost:2300/api/agents/Bond HTTP/1.1
Accept: text/html, application/xhtml+xml, */*
Accept-Language: en-US,en;q=0.7,he;q=0.3
User-Agent: Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; WOW64; Trident/6.0)
Accept-Encoding: gzip, deflate
Host: localhost:2300
DNT: 1
Connection: Keep-Alive

32

Recommended for you

Asp dot net final (2)
Asp dot net   final (2)Asp dot net   final (2)
Asp dot net final (2)

This document provides an overview of server-side ASP.NET technologies. It compares ASP.NET to PHP, discusses the problems with classic ASP that ASP.NET aimed to address, and outlines key ASP.NET concepts like the .NET Framework, ASPX files and code-behind files, page lifecycle, controls, state management, and configuration files. The document also covers ASP.NET execution process, advantages over classic ASP, and references additional resources for further information.

DITEC - E-Commerce & ASP.NET
DITEC - E-Commerce & ASP.NETDITEC - E-Commerce & ASP.NET
DITEC - E-Commerce & ASP.NET

This document provides an overview of e-commerce and ASP.NET. It defines e-commerce as buying and selling products or services over electronic systems like the internet. It describes different e-commerce models including business-to-business, business-to-consumer, and consumer-to-consumer. It then explains what ASP.NET is and how it can be used to build dynamic web pages and applications. It provides details on ASP.NET features, controls, events, and how to pass data between pages.

ditecasp.netesoft
ASP.NET Core Security
ASP.NET Core SecurityASP.NET Core Security
ASP.NET Core Security

Folien des Vortrags ASP.NET Core Security bei der .net user group Köln am 13. Dezember 2016

asp.net corecookiesclaims based authorization
HTTP RESPONSE MESSAGES

HTTP/1.1 200 OK
Cache-Control: public, max-age=300
Content-Type: application/json; charset=utf-8
ETag: "1"
Server: Microsoft-IIS/8.0
X-AspNet-Version: 4.0.30319
Date: Mon, 19 Nov 2012 17:49:40 GMT
Content-Length: 142
{

"Id": "Bond",
"FullName": "James Bond",
"Alias": "007",
"Version": 1,
"Image": "http://localhost:2300/api/agents/Bond.jpg"
}

33
URIS
•

HTTP is not an RPC protocol

•

HTTP uses URIs to identify resources over the network

•

An HTTP URI has the following basic structure:

http://theagency.com:8080/agents?id=1
Schema

Host

Port

Absolute
Path

Query

34
CLEAN URLS AND ASP.NET
 Using clean URLs can be a problem with IIS
 IIS needs extensions to map requests to handlers
 Without extensions, IIS is lost
 ASP.NET Routing to the rescue with UrlRoutingModule
 It’s all about patterns… and mapping them to handlers
 The starting point of MVC, Dynamic Data, and Web API

 System.Web.Routing.RouteTable.Routes.MapHttpRoute

RouteTable.Routes.MapHttpRoute(
name: "DefaultApi",
routeTemplate: "api/{controller}/{id}",
defaults: new { id = RouteParameter.Optional }
);

35
ASP.NET WEB API - ROUTING
36

Recommended for you

DITEC - Programming with Java
DITEC - Programming with JavaDITEC - Programming with Java
DITEC - Programming with Java

Esoft Metro Campus - Diploma in Information Technology - (Module VIII) Programming with Java (Template - Virtusa Corporate) Contents: Introduction to Java Features of Java What you can create by Java? Start Java Programming Creating First Java Program Java Virtual Machine Basic Rules to Remember Keywords in Java Comments in Java Programs Printing Statements Primitive Data Types in Java Arithmetic Operators Assignment Operators Comparison Operators Logical Operators If Statement If… Else Statement If… Else if… Else Statement Nested If Statement While Loop Do While Loop For Loop Reading User Input Arrays Two Dimensional Arrays Objects and Classes Java Classes Java Objects Methods with Return Value Methods without Return Value Method Overloading Variable Types Inheritance Method Overriding Access Modifiers Packages GUI Applications in Java Java Applets

javaditecesoft
Writing clean code in C# and .NET
Writing clean code in C# and .NETWriting clean code in C# and .NET
Writing clean code in C# and .NET

Maintaining the product is one (if not the most) expensive area of the overall product costs. Writing clean code can significantly lower these costs, making it more efficient during the initial development and results in more stable code. In this session participants will learn how to apply C# techniques in order to improve the efficiency, readability, testability and extensibility of code.

clean codeagile software developmentsolid
Concepts of Asp.Net
Concepts of Asp.NetConcepts of Asp.Net
Concepts of Asp.Net

This document provides an agenda for a presentation on ASP.NET fundamentals including programming models, design goals, architecture, and CLR services. It discusses how ASP.NET unifies programming models and simplifies development. It describes the Common Language Runtime, including design goals to simplify development and deployment while providing a robust execution environment. It also summarizes CLR services like type safety, memory management, and metadata.

programming models design goals and architecture cdistance educationonline certification courses
Routing with attributes


Why attributes over convention?
 Child (sub) resources
 Multiple type of parameters or return

values
 Versioning of actions and controllers


Start by enabling attribute routing
 config.MapHttpAttributeRoutes();

[RoutePrefix("api/agents/{agentId}")]
public class ObservationsController : ApiController
{
// GET api/agents/bond/observations
[HttpGet("observations/{date}")]
public Observation Get(string agentId, DateTime date) { ... }
}
Verbs
• HTTP defines a set of Methods or Verbs
that add an action-like semantics to
requests
• Verbs are defined as the first segment of
• the request-line:
GET http://localhost:4392/travelers/1 HTTP/1.1

• There are eight verbs defined in HTTP
1.1:
GET
POST
PUT
DELETE

HEAD
OPTIONS
TRACE
CONNECT

38
3, 2, 1, Actions!
• Actions are matched by HTTP verb names and
the existence of parameters
public class ProductsController : ApiController
{
public IEnumerable<Product> GetProducts() {...}
public Product GetProductById(int id) {...}
public HttpResponseMessage PostProduct(Product product) {...}
}

GET api/products
GET api/products/42
POST api/products
DELETE api/products/42
Status Codes
 Status codes describe the result of the server’s effort

to satisfy the request
 Passed in the response's status-line as three digit
alongside a textual description called reason phrase
 HTTP has five different categories of status-codes:






1xx – Informational
2xx – Success
3xx – Redirection
4xx – Client Error
5xx – Server Error

(100 / 101)
(200 – 206)
(300 – 307)
(400 – 417)
(500 – 505)

Recommended for you

DIWE - Coding HTML for Basic Web Designing
DIWE - Coding HTML for Basic Web DesigningDIWE - Coding HTML for Basic Web Designing
DIWE - Coding HTML for Basic Web Designing

Esoft Metro Campus - Diploma in Web Engineering - (Module III) Coding HTML for Basic Web Designing (Template - Virtusa Corporate) Contents: Introduction to HTML HTML Versions HTML Standards Creating a Simple HTML Document Document Type Declaration Comments in HTML HTML Attributes Paragraphs Line Break Headings Text Formatting Font Formatting Images Hyperlinks Page Body Lists Tables Cell Merging in a Table Table Attributes Horizontal Rule Iframes HTML Blocks Division Span Audio Video Youtube Videos Forms and Input Introduction to CSS Advantages of Using CSS CSS Syntax CSS Comments How to Insert CSS? CSS Tag, ID and Class Selectors Grouping and Nesting Selectors CSS Backgrounds CSS Text CSS Fonts CSS Links CSS Lists CSS Tables CSS Box Model CSS Dimension CSS Display - Block and Inline CSS Positioning CSS Float CSS Alignment Navigation Menu in CSS

diweweb engineeringesoft
ASP.NET Presentation
ASP.NET PresentationASP.NET Presentation
ASP.NET Presentation

ASP.NET is a server-side web application framework designed for web development to produce dynamic web pages. It was developed by Microsoft to allow programmers to build dynamic websites, web applications, and web services. ASP.NET uses a compiled execution model whereby code is typically written in C# or Visual Basic .NET and compiled to bytecode that is executed by the Common Language Runtime.

DIWE - Programming with JavaScript
DIWE - Programming with JavaScriptDIWE - Programming with JavaScript
DIWE - Programming with JavaScript

Esoft Metro Campus - Diploma in Web Engineering - (Module V) Programming with JavaScript (Template - Virtusa Corporate) Contents: Introduction to JavaScript What JavaScript Can Do? Script tag in HTML Noscript tag in HTML Your First JavaScript Program JavaScript Placement in HTML File JavaScript Syntax JavaScript Data Types JavaScript Variables JavaScript Identifiers Arithmetic Operators String Concatenation Operators Assignment Operators Comparison Operators Logical Operators Bitwise Operators If Statement If… Else Statement If… Else if… Else Statement Switch Statement The ? Operator While Loop Do While Loop For Loop For…in Loop break Statement continue Statement Arrays Functions JavaScript Objects JavaScript Scope Strings Regular Expressions JavaScript Numbers Math Object Date and Time JavaScript Events Dialog Boxes Error Handling in JavaScript JavaScript Forms Validation JavaScript HTML DOM JavaScript BOM

web engineeringjavascriptesoft
Status Code examples
•
•
•
•
•
•
•
•
41

404?
401?
304?
503?
500?
200?
301?
302?


Returning an HttpResponseMessage
allows more control over the response,
including:




Status code
HTTP headers
Entity body

public HttpResponseMessage CreateAgent(Agent agent)
{
agent = _repository.Add(agent);
var response =
Request.CreateResponse<Agent>(HttpStatusCode.Created, agent);
response.Headers.Location = GetAgentLocation(agent.Id);
return response;
}

42
Error Handling
• In HTTP services errors are handled by
▫ Returning an appropriate status code
▫ Returning an entity body explaining the error
(when applicable)

• Web API allows you to handle exceptions by
▫ Return an HttpResponseMessage with
appropriate status code (404, 500 …)
▫ Throw an HttpResponseException
▫ Create a general exception handler by using Filters
43
HTTP defines a process to best match the
server’s response to the client’s expectation
 Negotiation can be done using:


 Headers:

Accept, Accept- Language, Accept- Charset,
Accept-Encoding
 URI:
File extensions (.jpeg, .html), host-name: (com,
org), path and query

44

Recommended for you

Developing an aspnet web application
Developing an aspnet web applicationDeveloping an aspnet web application
Developing an aspnet web application

The document provides information about Satyam Software Solutions Pvt. Ltd., including that they develop embedded systems and provide cost-effective solutions for organizations. They are developing a flexible and manageable NANO OS for sensor networks and robotics. They also offer hardware development services like microprocessor board development and custom board development.

DIWE - Introduction to Web Technologies
DIWE - Introduction to Web TechnologiesDIWE - Introduction to Web Technologies
DIWE - Introduction to Web Technologies

ESOFT Computer Studies - Diploma in Web Engineering - (Module I) Introduction to Web Technologies (Template - Virtusa Corporate)

internetweb designweb
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET

For web developer this presentation is very helpful as it provide useful knowledge of the latest web technology that is ASP.NET

asp.netaspweb language
ASP.NET, IIS & how to create virtual
directory
SESSION OBJECTIVES
•
•
•
•
•
•

ASP.NET Benefit
How Does ASP.NET Work?
IIS
Creating a Virtual Directory
Web Sharing the Project Folder
Deleting a Web Project
HOW DOES ASP.NET WORK?
• Requests an HTML file, the server returns the file

• Requests an ASP.NET file, IIS passes the request to
the ASP.NET engine on the server
• The ASP.NET engine reads the file, line by line, and
executes the scripts in the file
• ASP.NET file is returned to the browser as plain HTML


Separation of Code from HTML



Graphical Development Environment



Update files while the server is running!



Support for compiled languages



State management

Recommended for you

ASP.NET Tutorial - Presentation 1
ASP.NET Tutorial - Presentation 1ASP.NET Tutorial - Presentation 1
ASP.NET Tutorial - Presentation 1

ASP.NET is a Microsoft web technology used to create dynamic web applications and services. It allows for server-side scripting, state management, and easy updating of files while the server is running. An ASP.NET file contains HTML, XML, and scripts that are executed on the server before being returned as plain HTML. IIS (Internet Information Services) is the Microsoft web server that processes ASP.NET files. It passes ASP.NET file requests to the ASP.NET engine, which reads and executes the scripts before returning the file as HTML to the browser. Virtual directories in IIS are used to share project folders so that ASP.NET files and applications can be accessed online.

asp.nettutorialnet
Asp.net.
Asp.net.Asp.net.
Asp.net.

This document provides an introduction and overview of ASP.NET and Web Forms. It discusses the background of ASP and how ASP.NET was developed to address challenges with ASP. The key features of ASP.NET, including Web Forms, Web Services, and the .NET Framework are described. The document then covers the ASP.NET programming model based on controls and events, and how postbacks maintain page state without requiring additional code. It also introduces the ASP.NET object model and server-side controls.

ASP.Net | Sabin Saleem
ASP.Net | Sabin SaleemASP.Net | Sabin Saleem
ASP.Net | Sabin Saleem

ASP.NET MVC is a web application framework that implements the model-view-controller pattern. It provides a clear separation of concerns between the application's data model, user interface, and logic. Some key benefits of ASP.NET MVC include test-driven development, full control over HTML and JavaScript, and a directory structure that separates the model, views, and controllers. The MVC pattern involves the view displaying data from the model, the controller handling input and updating the model, and the updated model notifying the view of changes.

webweb designcomputer
IIS – Internet Information Services
• Internet Information Service
• IIS (Internet Information Services) is Microsoft's
Internet server
• IIS comes as a free component with Windows
servers
• IIS is also a part of Windows 2000 and XP
Professional








Start, Settings, Control Panel, Administrative
Tools, Internet Services Manager
Expand node for computer and default Web
site
Right-click Default Web site icon, select New,
Virtual Directory
In Virtual Directory Creation Wizard enter
your project folder name as the alias and enter
the folder and path
Web Sharing the Project Folder
 Select the Project folder in My Computer
 Right-click, select Properties, Web Sharing, activate

Share This Folder
 In Edit Alias dialog click OK
Deleting a Web Project


Project in IIS Virtual Directory
 Delete the directory



Project in Web Shared Folder
 “Unshare” it from Properties dialog
 Either Reboot Computer or Stop and Restart IIS
 Delete Folder

Recommended for you

Web development concepts using microsoft technologies
Web development concepts using microsoft technologiesWeb development concepts using microsoft technologies
Web development concepts using microsoft technologies

This document summarizes a presentation about web development concepts using Microsoft technologies. It introduces ASP.NET as a framework for building web applications in C# or VB.NET using Visual Studio. It describes ASP.NET features like controls, page lifecycle, and different coding styles. It also discusses recent additions like AJAX, jQuery, LINQ, MVC, and the Microsoft web platform. The presentation aims to provide an overview of Microsoft web technologies and how they can help developers build web applications.

aspnetweb platformmicrosoft
Asp.net
Asp.netAsp.net
Asp.net

The document provides an overview of Microsoft ASP.NET, describing what it is, its advantages, and how it works. Key points include: ASP.NET provides a programming model and infrastructure for developing web applications using .NET languages and services; it offers advantages like compiled pages, XML configuration, and server controls; applications can be built as web forms or web services; and the .NET Framework provides a large class library for ASP.NET applications to utilize.

asp.net
Top 10 - ASP.NET Interview Questions And Answers 2023.pdf
Top 10 -  ASP.NET Interview Questions And Answers 2023.pdfTop 10 -  ASP.NET Interview Questions And Answers 2023.pdf
Top 10 - ASP.NET Interview Questions And Answers 2023.pdf

This document provides an introduction and overview of the top 10 ASP.NET interview questions and their answers. It discusses what ASP.NET is, its key features like being an open-source web application framework part of the .NET platform. It also summarizes some important ASP.NET concepts like the Common Language Runtime, MVC framework, Server Controls, the web.config and Global.asax files.

asp.net coreasp.net mvc
Thank You All

More Related Content

What's hot

Atul Shende_Final CV
Atul Shende_Final CVAtul Shende_Final CV
Atul Shende_Final CV
Atul Shende
 
Suman
SumanSuman
Resume
ResumeResume
Online computer lab management system
Online computer lab management systemOnline computer lab management system
Online computer lab management system
Pranyta Karhe
 
java mini project for college students
java mini project for college students java mini project for college students
java mini project for college students
SWETALEENA2
 
TestingResume_3.6Yrs
TestingResume_3.6YrsTestingResume_3.6Yrs
TestingResume_3.6Yrs
McAfee
 
Synopsis on online shopping by sudeep singh
Synopsis on online shopping by  sudeep singhSynopsis on online shopping by  sudeep singh
Synopsis on online shopping by sudeep singh
Sudeep Singh
 
Project report On MSM (Mobile Shop Management)
Project report On MSM (Mobile Shop Management)Project report On MSM (Mobile Shop Management)
Project report On MSM (Mobile Shop Management)
Dinesh Jogdand
 
Manjeet aem
Manjeet aemManjeet aem
Manjeet aem
Manjeet kumar
 
News portal
News portalNews portal
News portal
Arman Ahmed
 
mini_Project_SRS
mini_Project_SRSmini_Project_SRS
mini_Project_SRS
Vayodya Tamari
 
Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform
Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration PlatformMicrosoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform
Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform
Edureka!
 
Task tracking system
Task tracking systemTask tracking system
Task tracking system
Maulik Thaker
 
Pulkit Sachdeva-Resume
Pulkit Sachdeva-ResumePulkit Sachdeva-Resume
Pulkit Sachdeva-Resume
Pulkit Sachdeva
 
Zarafa Repair is Possible in Few Clicks
Zarafa Repair is Possible in Few ClicksZarafa Repair is Possible in Few Clicks
Zarafa Repair is Possible in Few Clicks
macbethben
 
Cv vipul valvi_java_developer
Cv vipul valvi_java_developerCv vipul valvi_java_developer
Cv vipul valvi_java_developer
vipulvalvi3
 
A Software Engineering Project on Cyber cafe management
A Software Engineering Project on Cyber cafe managementA Software Engineering Project on Cyber cafe management
A Software Engineering Project on Cyber cafe management
svrohith 9
 
Work experiences at Softcodeit
Work experiences at SoftcodeitWork experiences at Softcodeit
Work experiences at Softcodeit
Vayodya Tamari
 
Design & development of job portal system using joomla & its online reputatio...
Design & development of job portal system using joomla & its online reputatio...Design & development of job portal system using joomla & its online reputatio...
Design & development of job portal system using joomla & its online reputatio...
Dinesh Babu Pugalenthi
 
Goal setting
Goal settingGoal setting
Goal setting
VijayIvaturi1
 

What's hot (20)

Atul Shende_Final CV
Atul Shende_Final CVAtul Shende_Final CV
Atul Shende_Final CV
 
Suman
SumanSuman
Suman
 
Resume
ResumeResume
Resume
 
Online computer lab management system
Online computer lab management systemOnline computer lab management system
Online computer lab management system
 
java mini project for college students
java mini project for college students java mini project for college students
java mini project for college students
 
TestingResume_3.6Yrs
TestingResume_3.6YrsTestingResume_3.6Yrs
TestingResume_3.6Yrs
 
Synopsis on online shopping by sudeep singh
Synopsis on online shopping by  sudeep singhSynopsis on online shopping by  sudeep singh
Synopsis on online shopping by sudeep singh
 
Project report On MSM (Mobile Shop Management)
Project report On MSM (Mobile Shop Management)Project report On MSM (Mobile Shop Management)
Project report On MSM (Mobile Shop Management)
 
Manjeet aem
Manjeet aemManjeet aem
Manjeet aem
 
News portal
News portalNews portal
News portal
 
mini_Project_SRS
mini_Project_SRSmini_Project_SRS
mini_Project_SRS
 
Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform
Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration PlatformMicrosoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform
Microsoft Sharepoint 2013 : The Ultimate Enterprise Collaboration Platform
 
Task tracking system
Task tracking systemTask tracking system
Task tracking system
 
Pulkit Sachdeva-Resume
Pulkit Sachdeva-ResumePulkit Sachdeva-Resume
Pulkit Sachdeva-Resume
 
Zarafa Repair is Possible in Few Clicks
Zarafa Repair is Possible in Few ClicksZarafa Repair is Possible in Few Clicks
Zarafa Repair is Possible in Few Clicks
 
Cv vipul valvi_java_developer
Cv vipul valvi_java_developerCv vipul valvi_java_developer
Cv vipul valvi_java_developer
 
A Software Engineering Project on Cyber cafe management
A Software Engineering Project on Cyber cafe managementA Software Engineering Project on Cyber cafe management
A Software Engineering Project on Cyber cafe management
 
Work experiences at Softcodeit
Work experiences at SoftcodeitWork experiences at Softcodeit
Work experiences at Softcodeit
 
Design & development of job portal system using joomla & its online reputatio...
Design & development of job portal system using joomla & its online reputatio...Design & development of job portal system using joomla & its online reputatio...
Design & development of job portal system using joomla & its online reputatio...
 
Goal setting
Goal settingGoal setting
Goal setting
 

Viewers also liked

Monitoring web application response times, a new approach
Monitoring web application response times, a new approachMonitoring web application response times, a new approach
Monitoring web application response times, a new approach
Mark Friedman
 
ASP.NET Best Practices - Useful Tips from the Trenches
ASP.NET Best Practices - Useful Tips from the TrenchesASP.NET Best Practices - Useful Tips from the Trenches
ASP.NET Best Practices - Useful Tips from the Trenches
Habeeb Rushdan
 
Introduction to asp.net
Introduction to asp.netIntroduction to asp.net
Introduction to asp.net
SHADAB ALI
 
Introduction to asp.net
Introduction to asp.netIntroduction to asp.net
Introduction to asp.net
shan km
 
Asp dot net final (2)
Asp dot net   final (2)Asp dot net   final (2)
Asp dot net final (2)
Amelina Ahmeti
 
DITEC - E-Commerce & ASP.NET
DITEC - E-Commerce & ASP.NETDITEC - E-Commerce & ASP.NET
DITEC - E-Commerce & ASP.NET
Rasan Samarasinghe
 
ASP.NET Core Security
ASP.NET Core SecurityASP.NET Core Security
ASP.NET Core Security
Albert Weinert
 
DITEC - Programming with Java
DITEC - Programming with JavaDITEC - Programming with Java
DITEC - Programming with Java
Rasan Samarasinghe
 
Writing clean code in C# and .NET
Writing clean code in C# and .NETWriting clean code in C# and .NET
Writing clean code in C# and .NET
Dror Helper
 
Concepts of Asp.Net
Concepts of Asp.NetConcepts of Asp.Net
Concepts of Asp.Net
vidyamittal
 
DIWE - Coding HTML for Basic Web Designing
DIWE - Coding HTML for Basic Web DesigningDIWE - Coding HTML for Basic Web Designing
DIWE - Coding HTML for Basic Web Designing
Rasan Samarasinghe
 
ASP.NET Presentation
ASP.NET PresentationASP.NET Presentation
ASP.NET Presentation
dimuthu22
 
DIWE - Programming with JavaScript
DIWE - Programming with JavaScriptDIWE - Programming with JavaScript
DIWE - Programming with JavaScript
Rasan Samarasinghe
 
Developing an aspnet web application
Developing an aspnet web applicationDeveloping an aspnet web application
Developing an aspnet web application
Rahul Bansal
 
DIWE - Introduction to Web Technologies
DIWE - Introduction to Web TechnologiesDIWE - Introduction to Web Technologies
DIWE - Introduction to Web Technologies
Rasan Samarasinghe
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
Rajkumarsoy
 
ASP.NET Tutorial - Presentation 1
ASP.NET Tutorial - Presentation 1ASP.NET Tutorial - Presentation 1
ASP.NET Tutorial - Presentation 1
Kumar S
 
Asp.net.
Asp.net.Asp.net.
Asp.net.
Naveen Sihag
 

Viewers also liked (18)

Monitoring web application response times, a new approach
Monitoring web application response times, a new approachMonitoring web application response times, a new approach
Monitoring web application response times, a new approach
 
ASP.NET Best Practices - Useful Tips from the Trenches
ASP.NET Best Practices - Useful Tips from the TrenchesASP.NET Best Practices - Useful Tips from the Trenches
ASP.NET Best Practices - Useful Tips from the Trenches
 
Introduction to asp.net
Introduction to asp.netIntroduction to asp.net
Introduction to asp.net
 
Introduction to asp.net
Introduction to asp.netIntroduction to asp.net
Introduction to asp.net
 
Asp dot net final (2)
Asp dot net   final (2)Asp dot net   final (2)
Asp dot net final (2)
 
DITEC - E-Commerce & ASP.NET
DITEC - E-Commerce & ASP.NETDITEC - E-Commerce & ASP.NET
DITEC - E-Commerce & ASP.NET
 
ASP.NET Core Security
ASP.NET Core SecurityASP.NET Core Security
ASP.NET Core Security
 
DITEC - Programming with Java
DITEC - Programming with JavaDITEC - Programming with Java
DITEC - Programming with Java
 
Writing clean code in C# and .NET
Writing clean code in C# and .NETWriting clean code in C# and .NET
Writing clean code in C# and .NET
 
Concepts of Asp.Net
Concepts of Asp.NetConcepts of Asp.Net
Concepts of Asp.Net
 
DIWE - Coding HTML for Basic Web Designing
DIWE - Coding HTML for Basic Web DesigningDIWE - Coding HTML for Basic Web Designing
DIWE - Coding HTML for Basic Web Designing
 
ASP.NET Presentation
ASP.NET PresentationASP.NET Presentation
ASP.NET Presentation
 
DIWE - Programming with JavaScript
DIWE - Programming with JavaScriptDIWE - Programming with JavaScript
DIWE - Programming with JavaScript
 
Developing an aspnet web application
Developing an aspnet web applicationDeveloping an aspnet web application
Developing an aspnet web application
 
DIWE - Introduction to Web Technologies
DIWE - Introduction to Web TechnologiesDIWE - Introduction to Web Technologies
DIWE - Introduction to Web Technologies
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
 
ASP.NET Tutorial - Presentation 1
ASP.NET Tutorial - Presentation 1ASP.NET Tutorial - Presentation 1
ASP.NET Tutorial - Presentation 1
 
Asp.net.
Asp.net.Asp.net.
Asp.net.
 

Similar to ASP.NET Presentation

ASP.Net | Sabin Saleem
ASP.Net | Sabin SaleemASP.Net | Sabin Saleem
ASP.Net | Sabin Saleem
SaBin SaleEm
 
Web development concepts using microsoft technologies
Web development concepts using microsoft technologiesWeb development concepts using microsoft technologies
Web development concepts using microsoft technologies
Hosam Kamel
 
Asp.net
Asp.netAsp.net
Top 10 - ASP.NET Interview Questions And Answers 2023.pdf
Top 10 -  ASP.NET Interview Questions And Answers 2023.pdfTop 10 -  ASP.NET Interview Questions And Answers 2023.pdf
Top 10 - ASP.NET Interview Questions And Answers 2023.pdf
Ruddarpratap
 
ASP.NET OVERVIEW
ASP.NET OVERVIEWASP.NET OVERVIEW
ASP.NET OVERVIEW
Rishi Kothari
 
Asp.Net Core MVC with Entity Framework
Asp.Net Core MVC with Entity FrameworkAsp.Net Core MVC with Entity Framework
Asp.Net Core MVC with Entity Framework
Shravan A
 
ASP, ASP.NET, JSP, COM/DCOM
ASP, ASP.NET, JSP, COM/DCOMASP, ASP.NET, JSP, COM/DCOM
ASP, ASP.NET, JSP, COM/DCOM
Aashish Jain
 
Programming is Fun with ASP.NET MVC
Programming is Fun with ASP.NET MVCProgramming is Fun with ASP.NET MVC
Programming is Fun with ASP.NET MVC
Ian Carnaghan
 
ASP.pptx
ASP.pptxASP.pptx
Session 1
Session 1Session 1
Session 1
Asif Atick
 
Asp.net mvc
Asp.net mvcAsp.net mvc
Asp.net mvc
Taranjeet Singh
 
Asp.net With mvc handson
Asp.net With mvc handsonAsp.net With mvc handson
Asp.net With mvc handson
Prashant Kumar
 
Beginners introduction to asp.net
Beginners introduction to asp.netBeginners introduction to asp.net
Beginners introduction to asp.net
Naveen Kumar Veligeti
 
ASP.NET MVC Fundamental
ASP.NET MVC FundamentalASP.NET MVC Fundamental
ASP.NET MVC Fundamental
ldcphuc
 
Best of Microsoft Dev Camp 2015
Best of Microsoft Dev Camp 2015Best of Microsoft Dev Camp 2015
Best of Microsoft Dev Camp 2015
Bluegrass Digital
 
JOB PORTALProject SummaryTitle JOB-PORT.docx
JOB PORTALProject SummaryTitle    JOB-PORT.docxJOB PORTALProject SummaryTitle    JOB-PORT.docx
JOB PORTALProject SummaryTitle JOB-PORT.docx
christiandean12115
 
Creating Dynamic Web Application Using ASP.Net 3 5_MVP Alezandra Buencamino N...
Creating Dynamic Web Application Using ASP.Net 3 5_MVP Alezandra Buencamino N...Creating Dynamic Web Application Using ASP.Net 3 5_MVP Alezandra Buencamino N...
Creating Dynamic Web Application Using ASP.Net 3 5_MVP Alezandra Buencamino N...
Quek Lilian
 
Asp.netrole
Asp.netroleAsp.netrole
Asp.netrole
mani bhushan
 
SynapseIndia asp.net2.0 ajax Development
SynapseIndia asp.net2.0 ajax DevelopmentSynapseIndia asp.net2.0 ajax Development
SynapseIndia asp.net2.0 ajax Development
Synapseindiappsdevelopment
 
ASP.NET MVC Presentation
ASP.NET MVC PresentationASP.NET MVC Presentation
ASP.NET MVC Presentation
ivpol
 

Similar to ASP.NET Presentation (20)

ASP.Net | Sabin Saleem
ASP.Net | Sabin SaleemASP.Net | Sabin Saleem
ASP.Net | Sabin Saleem
 
Web development concepts using microsoft technologies
Web development concepts using microsoft technologiesWeb development concepts using microsoft technologies
Web development concepts using microsoft technologies
 
Asp.net
Asp.netAsp.net
Asp.net
 
Top 10 - ASP.NET Interview Questions And Answers 2023.pdf
Top 10 -  ASP.NET Interview Questions And Answers 2023.pdfTop 10 -  ASP.NET Interview Questions And Answers 2023.pdf
Top 10 - ASP.NET Interview Questions And Answers 2023.pdf
 
ASP.NET OVERVIEW
ASP.NET OVERVIEWASP.NET OVERVIEW
ASP.NET OVERVIEW
 
Asp.Net Core MVC with Entity Framework
Asp.Net Core MVC with Entity FrameworkAsp.Net Core MVC with Entity Framework
Asp.Net Core MVC with Entity Framework
 
ASP, ASP.NET, JSP, COM/DCOM
ASP, ASP.NET, JSP, COM/DCOMASP, ASP.NET, JSP, COM/DCOM
ASP, ASP.NET, JSP, COM/DCOM
 
Programming is Fun with ASP.NET MVC
Programming is Fun with ASP.NET MVCProgramming is Fun with ASP.NET MVC
Programming is Fun with ASP.NET MVC
 
ASP.pptx
ASP.pptxASP.pptx
ASP.pptx
 
Session 1
Session 1Session 1
Session 1
 
Asp.net mvc
Asp.net mvcAsp.net mvc
Asp.net mvc
 
Asp.net With mvc handson
Asp.net With mvc handsonAsp.net With mvc handson
Asp.net With mvc handson
 
Beginners introduction to asp.net
Beginners introduction to asp.netBeginners introduction to asp.net
Beginners introduction to asp.net
 
ASP.NET MVC Fundamental
ASP.NET MVC FundamentalASP.NET MVC Fundamental
ASP.NET MVC Fundamental
 
Best of Microsoft Dev Camp 2015
Best of Microsoft Dev Camp 2015Best of Microsoft Dev Camp 2015
Best of Microsoft Dev Camp 2015
 
JOB PORTALProject SummaryTitle JOB-PORT.docx
JOB PORTALProject SummaryTitle    JOB-PORT.docxJOB PORTALProject SummaryTitle    JOB-PORT.docx
JOB PORTALProject SummaryTitle JOB-PORT.docx
 
Creating Dynamic Web Application Using ASP.Net 3 5_MVP Alezandra Buencamino N...
Creating Dynamic Web Application Using ASP.Net 3 5_MVP Alezandra Buencamino N...Creating Dynamic Web Application Using ASP.Net 3 5_MVP Alezandra Buencamino N...
Creating Dynamic Web Application Using ASP.Net 3 5_MVP Alezandra Buencamino N...
 
Asp.netrole
Asp.netroleAsp.netrole
Asp.netrole
 
SynapseIndia asp.net2.0 ajax Development
SynapseIndia asp.net2.0 ajax DevelopmentSynapseIndia asp.net2.0 ajax Development
SynapseIndia asp.net2.0 ajax Development
 
ASP.NET MVC Presentation
ASP.NET MVC PresentationASP.NET MVC Presentation
ASP.NET MVC Presentation
 

Recently uploaded

Configuring Single Sign-On (SSO) via Identity Management | MuleSoft Mysore Me...
Configuring Single Sign-On (SSO) via Identity Management | MuleSoft Mysore Me...Configuring Single Sign-On (SSO) via Identity Management | MuleSoft Mysore Me...
Configuring Single Sign-On (SSO) via Identity Management | MuleSoft Mysore Me...
MysoreMuleSoftMeetup
 
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
siemaillard
 
Webinar Innovative assessments for SOcial Emotional Skills
Webinar Innovative assessments for SOcial Emotional SkillsWebinar Innovative assessments for SOcial Emotional Skills
Webinar Innovative assessments for SOcial Emotional Skills
EduSkills OECD
 
AI_in_HR_Presentation Part 1 2024 0703.pdf
AI_in_HR_Presentation Part 1 2024 0703.pdfAI_in_HR_Presentation Part 1 2024 0703.pdf
AI_in_HR_Presentation Part 1 2024 0703.pdf
SrimanigandanMadurai
 
Split Shifts From Gantt View in the Odoo 17
Split Shifts From Gantt View in the  Odoo 17Split Shifts From Gantt View in the  Odoo 17
Split Shifts From Gantt View in the Odoo 17
Celine George
 
Is Email Marketing Really Effective In 2024?
Is Email Marketing Really Effective In 2024?Is Email Marketing Really Effective In 2024?
Is Email Marketing Really Effective In 2024?
Rakesh Jalan
 
ENGLISH-7-CURRICULUM MAP- MATATAG CURRICULUM
ENGLISH-7-CURRICULUM MAP- MATATAG CURRICULUMENGLISH-7-CURRICULUM MAP- MATATAG CURRICULUM
ENGLISH-7-CURRICULUM MAP- MATATAG CURRICULUM
HappieMontevirgenCas
 
How to Install Theme in the Odoo 17 ERP
How to  Install Theme in the Odoo 17 ERPHow to  Install Theme in the Odoo 17 ERP
How to Install Theme in the Odoo 17 ERP
Celine George
 
How to Show Sample Data in Tree and Kanban View in Odoo 17
How to Show Sample Data in Tree and Kanban View in Odoo 17How to Show Sample Data in Tree and Kanban View in Odoo 17
How to Show Sample Data in Tree and Kanban View in Odoo 17
Celine George
 
How to Add Colour Kanban Records in Odoo 17 Notebook
How to Add Colour Kanban Records in Odoo 17 NotebookHow to Add Colour Kanban Records in Odoo 17 Notebook
How to Add Colour Kanban Records in Odoo 17 Notebook
Celine George
 
Understanding and Interpreting Teachers’ TPACK for Teaching Multimodalities i...
Understanding and Interpreting Teachers’ TPACK for Teaching Multimodalities i...Understanding and Interpreting Teachers’ TPACK for Teaching Multimodalities i...
Understanding and Interpreting Teachers’ TPACK for Teaching Multimodalities i...
Neny Isharyanti
 
"DANH SÁCH THÍ SINH XÉT TUYỂN SỚM ĐỦ ĐIỀU KIỆN TRÚNG TUYỂN ĐẠI HỌC CHÍNH QUY ...
"DANH SÁCH THÍ SINH XÉT TUYỂN SỚM ĐỦ ĐIỀU KIỆN TRÚNG TUYỂN ĐẠI HỌC CHÍNH QUY ..."DANH SÁCH THÍ SINH XÉT TUYỂN SỚM ĐỦ ĐIỀU KIỆN TRÚNG TUYỂN ĐẠI HỌC CHÍNH QUY ...
"DANH SÁCH THÍ SINH XÉT TUYỂN SỚM ĐỦ ĐIỀU KIỆN TRÚNG TUYỂN ĐẠI HỌC CHÍNH QUY ...
thanhluan21
 
Unlocking Educational Synergy-DIKSHA & Google Classroom.pptx
Unlocking Educational Synergy-DIKSHA & Google Classroom.pptxUnlocking Educational Synergy-DIKSHA & Google Classroom.pptx
Unlocking Educational Synergy-DIKSHA & Google Classroom.pptx
bipin95
 
The basics of sentences session 10pptx.pptx
The basics of sentences session 10pptx.pptxThe basics of sentences session 10pptx.pptx
The basics of sentences session 10pptx.pptx
heathfieldcps1
 
How to Create Sequence Numbers in Odoo 17
How to Create Sequence Numbers in Odoo 17How to Create Sequence Numbers in Odoo 17
How to Create Sequence Numbers in Odoo 17
Celine George
 
AI Risk Management: ISO/IEC 42001, the EU AI Act, and ISO/IEC 23894
AI Risk Management: ISO/IEC 42001, the EU AI Act, and ISO/IEC 23894AI Risk Management: ISO/IEC 42001, the EU AI Act, and ISO/IEC 23894
AI Risk Management: ISO/IEC 42001, the EU AI Act, and ISO/IEC 23894
PECB
 
How to Handle the Separate Discount Account on Invoice in Odoo 17
How to Handle the Separate Discount Account on Invoice in Odoo 17How to Handle the Separate Discount Account on Invoice in Odoo 17
How to Handle the Separate Discount Account on Invoice in Odoo 17
Celine George
 
Bedok NEWater Photostory - COM322 Assessment (Story 2)
Bedok NEWater Photostory - COM322 Assessment (Story 2)Bedok NEWater Photostory - COM322 Assessment (Story 2)
Bedok NEWater Photostory - COM322 Assessment (Story 2)
Liyana Rozaini
 
How to Store Data on the Odoo 17 Website
How to Store Data on the Odoo 17 WebsiteHow to Store Data on the Odoo 17 Website
How to Store Data on the Odoo 17 Website
Celine George
 

Recently uploaded (20)

Configuring Single Sign-On (SSO) via Identity Management | MuleSoft Mysore Me...
Configuring Single Sign-On (SSO) via Identity Management | MuleSoft Mysore Me...Configuring Single Sign-On (SSO) via Identity Management | MuleSoft Mysore Me...
Configuring Single Sign-On (SSO) via Identity Management | MuleSoft Mysore Me...
 
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
 
Webinar Innovative assessments for SOcial Emotional Skills
Webinar Innovative assessments for SOcial Emotional SkillsWebinar Innovative assessments for SOcial Emotional Skills
Webinar Innovative assessments for SOcial Emotional Skills
 
AI_in_HR_Presentation Part 1 2024 0703.pdf
AI_in_HR_Presentation Part 1 2024 0703.pdfAI_in_HR_Presentation Part 1 2024 0703.pdf
AI_in_HR_Presentation Part 1 2024 0703.pdf
 
Split Shifts From Gantt View in the Odoo 17
Split Shifts From Gantt View in the  Odoo 17Split Shifts From Gantt View in the  Odoo 17
Split Shifts From Gantt View in the Odoo 17
 
Is Email Marketing Really Effective In 2024?
Is Email Marketing Really Effective In 2024?Is Email Marketing Really Effective In 2024?
Is Email Marketing Really Effective In 2024?
 
ENGLISH-7-CURRICULUM MAP- MATATAG CURRICULUM
ENGLISH-7-CURRICULUM MAP- MATATAG CURRICULUMENGLISH-7-CURRICULUM MAP- MATATAG CURRICULUM
ENGLISH-7-CURRICULUM MAP- MATATAG CURRICULUM
 
How to Install Theme in the Odoo 17 ERP
How to  Install Theme in the Odoo 17 ERPHow to  Install Theme in the Odoo 17 ERP
How to Install Theme in the Odoo 17 ERP
 
How to Show Sample Data in Tree and Kanban View in Odoo 17
How to Show Sample Data in Tree and Kanban View in Odoo 17How to Show Sample Data in Tree and Kanban View in Odoo 17
How to Show Sample Data in Tree and Kanban View in Odoo 17
 
“A NOSSA CA(U)SA”. .
“A NOSSA CA(U)SA”.                      .“A NOSSA CA(U)SA”.                      .
“A NOSSA CA(U)SA”. .
 
How to Add Colour Kanban Records in Odoo 17 Notebook
How to Add Colour Kanban Records in Odoo 17 NotebookHow to Add Colour Kanban Records in Odoo 17 Notebook
How to Add Colour Kanban Records in Odoo 17 Notebook
 
Understanding and Interpreting Teachers’ TPACK for Teaching Multimodalities i...
Understanding and Interpreting Teachers’ TPACK for Teaching Multimodalities i...Understanding and Interpreting Teachers’ TPACK for Teaching Multimodalities i...
Understanding and Interpreting Teachers’ TPACK for Teaching Multimodalities i...
 
"DANH SÁCH THÍ SINH XÉT TUYỂN SỚM ĐỦ ĐIỀU KIỆN TRÚNG TUYỂN ĐẠI HỌC CHÍNH QUY ...
"DANH SÁCH THÍ SINH XÉT TUYỂN SỚM ĐỦ ĐIỀU KIỆN TRÚNG TUYỂN ĐẠI HỌC CHÍNH QUY ..."DANH SÁCH THÍ SINH XÉT TUYỂN SỚM ĐỦ ĐIỀU KIỆN TRÚNG TUYỂN ĐẠI HỌC CHÍNH QUY ...
"DANH SÁCH THÍ SINH XÉT TUYỂN SỚM ĐỦ ĐIỀU KIỆN TRÚNG TUYỂN ĐẠI HỌC CHÍNH QUY ...
 
Unlocking Educational Synergy-DIKSHA & Google Classroom.pptx
Unlocking Educational Synergy-DIKSHA & Google Classroom.pptxUnlocking Educational Synergy-DIKSHA & Google Classroom.pptx
Unlocking Educational Synergy-DIKSHA & Google Classroom.pptx
 
The basics of sentences session 10pptx.pptx
The basics of sentences session 10pptx.pptxThe basics of sentences session 10pptx.pptx
The basics of sentences session 10pptx.pptx
 
How to Create Sequence Numbers in Odoo 17
How to Create Sequence Numbers in Odoo 17How to Create Sequence Numbers in Odoo 17
How to Create Sequence Numbers in Odoo 17
 
AI Risk Management: ISO/IEC 42001, the EU AI Act, and ISO/IEC 23894
AI Risk Management: ISO/IEC 42001, the EU AI Act, and ISO/IEC 23894AI Risk Management: ISO/IEC 42001, the EU AI Act, and ISO/IEC 23894
AI Risk Management: ISO/IEC 42001, the EU AI Act, and ISO/IEC 23894
 
How to Handle the Separate Discount Account on Invoice in Odoo 17
How to Handle the Separate Discount Account on Invoice in Odoo 17How to Handle the Separate Discount Account on Invoice in Odoo 17
How to Handle the Separate Discount Account on Invoice in Odoo 17
 
Bedok NEWater Photostory - COM322 Assessment (Story 2)
Bedok NEWater Photostory - COM322 Assessment (Story 2)Bedok NEWater Photostory - COM322 Assessment (Story 2)
Bedok NEWater Photostory - COM322 Assessment (Story 2)
 
How to Store Data on the Odoo 17 Website
How to Store Data on the Odoo 17 WebsiteHow to Store Data on the Odoo 17 Website
How to Store Data on the Odoo 17 Website
 

ASP.NET Presentation

  • 1. JATIYA KABI KAZI NAZRUL ISLAM UNIVERSITY Presentation On Submitted to Mr. Tushar Kanti Saha Lecturer Deprt of CSE, JKKNIU Submitted By Rasel khan Roll: 11102027 Session: 2010-2011 Dept Of CSE
  • 2. ASP.NET OVERVIEW  Introduction & History  Why use ASP.NET, Some characteristics & with Component  Steps for developing a web based application and how to work request with response.  Working with ASP.NET MVC Framework.  How to work HTTP Fundamentals.  ASP.NET web application Routing.  ASP.NET IIS & how to create virtual directory.
  • 3. ASP.NET mean is Active Server Pages . It is a server-side Web application framework designed for Web development to produce dynamic Web pages .It was developed by Microsoft to allow programmers to build , • Dynamic web sites, • Web applications • Web services
  • 4. • The latest version of ASP is known as ASP.NET • Visual Studio .NET is a developer application used to create ASP.NET Web applications • There are two main types of Web resources created with ASP.NET applications – Web Forms are ASP.NET pages within an ASP.NET application – Web Services are ASP.NET Web pages that contain publicly exposed code so that other applications can interact with them – Web Services are identified with the file extension .asmx
  • 5. ASP.NET 1.0 was released on January 5, 2002 as part of version 1.0 of the .NET Framework. Scott Guthrie became the product unit manager for ASP.NET, and development continued apace, with version 1.1 being released on April 24, 2003 as a part of Windows Server 2003. This release focused on improving ASP.NET's support for mobile devices.
  • 6.  Improved Performance and Scalability.  Compiled Execution, Rich Output Caching, Web Farm Session State.  Enhanced Reliability.  Memory Leak, Dead Lock, and Crash Protection  Easy Deployment.  No Touch" Application Deployment, Dynamic Update of Running Application, Easy Migration Path  New Application Models.  XML Web Services  Developer Productivity.  Easy Programming Model, Flexible Language Options, Rich Class Framework.
  • 7.  Code-behind model  It is recommended by Microsoft for dealing with dynamic program code to use the code-behind model, which places this code in a separate file or in a specially designated script tag  User  controls ASP.NET supports creating reusable components through the creation of User Controls  Rendering technique  ASP.NET uses a visited composites rendering technique. During compilation, the template (.aspx) file is compiled into initialization code which builds a control tree (the composite) representing the original template
  • 8. • Compiled code  Code written in ASP.NET is compile and not interpreted. • Enriched tool support  ASP.NET applications using visual studio • Power and flexibility  ASP.NET applications are based on the CLR • Simplicity  ASP.NET enables you to build user interfaces that separate application logic from presentation content • Manageability  ASP.NET provides a number of options in providing the above facilities
  • 9.  Server control Respond to users events by running event procedures on the server.  HTML control Represent the standard visual elements provided in HTML  Data control Provide a way to connect to perform commands on and retrieve data from SQL , OL ,databases and XML data files  System components Provide access to various system level events that occur on the server
  • 10. Step 1 – Step 2 Step 3 Step 4 Step 5 Step 6 Step 7 – – – – – – Create Local Folders for Your Web Project Create a Blank Solution Add a Web Site to Your Solution Add a Class Library (Optional) Check Your Solution Structure Check Your Local Folder Structure Add Your Solution to Source Control
  • 11. Web Server Web Browser Get default.aspx 1. Client Initiates 2. Communications With page request Display page Server response with pages 1. Process request 2. Execute server slide code 3. Store session data 4. Send result response
  • 14. ASP.NET MVC Model View Controller (MVC) applications by using the ASP.NET framework
  • 15. WHAT IS ASP.NET MVC? Saying simply, ASP.NET MVC is a new framework from Microsoft that sits over standard ASP.NET engine. ASP.NET MVC ASP.NET
  • 16. ASP.NET MVC Features 1. Clear separation of logic: Model, View, Controller 2. Test-Driven Development (TDD) 3. Full control over HTML and JavaScript 4. Friendly URLs
  • 17. MODEL + VIEW + CONTROLLER = MVC ASP.NET MVC provides an alternative to the ASP.NET “Web Forms” pattern for creating MVC-based Web applications. Views display the application's user interface (UI). Typically, this UI is created from the model data. Model objects implement the logic for the application's data domain. Often, model objects retrieve and store the app state in a database. Model View Controller Controllers handle user interaction, work with the model, and select a view to render that displays UI
  • 18. Test-Driven Development (TDD) Since the UI is completely separated from the business logic, it’s now easy to write Unit Tests for the ASP.NET MVC application. Unit Tests that cover User Actions and Data Model User Interface Controller Data Objects
  • 19. Full control over HTML & JS In ASP.NET MVC, designed HTML & JS pages are not more messed up with “postbacks” and “ViewStates”, which is specific for “Web-forms” pattern. <input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE" value="/wEPaA8FDzhjYjBhZjA0ODYyMTM2NBgGBR5fX0NvbnRyb2xzUmVxdWlyZVBvc3RCYWNr S2V5X18WAQUhY3RsMDAkaGVhZGVyJHVjTWFpbk1lbnUkc2VhcmNoQnRuBTdjdGwwMCRNYWl uQ29udGVudCRycHRWaWRlbyRjdGwwMyRwcmVzZW50YXRpb25DYXJkJG11bHRp" /> <script type="text/javascript"> //<![CDATA[ var theForm = document.forms['aspnetForm']; function __doPostBack(eventTarget, eventArgument) { if (!theForm.onsubmit || (theForm.onsubmit() != false)) { theForm.__EVENTTARGET.value = eventTarget; theForm.__EVENTARGUMENT.value = eventArgument; theForm.submit(); } } //]]> </script>
  • 20. Friendly URLs MVC binds web paths to the logical URLs rather than to the physical files. Physical location: C:InetpubwwwrootWebSiteProducts.aspx ASP.NET style: http://www.website.com/Products.aspx?name=Me at MVC style: http://www.website.com/Products/Meat
  • 21. HOW DOES ASP.NET MVC LOOKS LIKE? ASP.NET MVC installs a new type of web project into VS2008.
  • 22. A newly created project has an ASP.NET MVC specific directory structure. App_Data folder is the physical store for data. Content folder keeps files such as scripts, CSS, images, and so on. Controllers folder is the location for controllers. The MVC framework requires the names of all controllers to end with "Controller"—for example, HomeController, LoginController, or ProductController. Models stores classes that handle application business logic. Scripts folder is for script files that support the application. By default, this folder contains AJAX script files and the JQuery library. Views is the recommended location for views. Views use .aspx, .ascx, and .master files, in addition to any other files that are related to rendering views.
  • 23. ASP.NET MVC supports pure MVC pattern, the same development pattern Rails are based on. The advantages of ASP.NET MVC applications: 1. It makes it easier to manage complexity by dividing an application into the model, the view, and the controller. 2. It does not use view state or server-based forms. 3. It uses a Front Controller pattern that processes Web application requests through a single controller. This enables you to design an application that supports a rich routing infrastructure with friendly URLs. 4. It provides better support for test-driven development (TDD). 5. It works well for Web applications that are supported by large teams of developers and Web designers who need a high degree of control over the application behavior.
  • 24.  http://www.asp.net/mvc - official site  http://weblogs.asp.net/scottgu/archive/2007/11/13/asp-net-mvcframework-part-1.aspx - development basics on ASP.NET MVC  http://weblogs.asp.net/scottgu/archive/2007/12/03/asp-net-mvcframework-part-2-url-routing.aspx - URL routing used in ASP.NET MVC  http://weblogs.asp.net/scottgu/archive/2007/12/06/asp-net-mvcframework-part-3-passing-viewdata-from-controllers-to-views.aspx interaction between Controllers and Views  http://weblogs.asp.net/scottgu/archive/2007/12/09/asp-net-mvcframework-part-4-handling-form-edit-and-post-scenarios.aspx - managing form input data
  • 25. ASP.NET Web API and HTTP Fundamentals
  • 26. CRAMMING YOUR BRAINS WITH HTTP & ASP.NET WEB API • HTTP Fundamentals via Web API • Dependency Resolver • HTTP Messages • URIs • HTTP.SYS • Routing • IIS 101 • Verbs • HTTP compression • Controllers and Actions • Persisted Connections • Status Codes • Web API Self Hosting • HttpRequestMessage HttpResponseMessage • Error Handling • Content Negotiation • Media Type Formatters • OData • Validations • • Hosting More HTTP and Web API • Caching • Concurrency • Security • Streaming • WebSockets & SignalR 26
  • 27. WHY IS HTTP IMPORTANT?  HTTP is a first class application layer protocol  Unlike other protocols it was created to support a single information system  That system happened to be the largest and main information system of the human race: 27
  • 28. NO REALLY, WHY? Today's systems face new challenges:  Broader reach of clients
  • 29. What About ASP.NET Web API? • The .NET platform never had a first class framework for HTTP-based services • WCF was created as a SOAP-based framework and never really matured to support HTTP 29
  • 30. THE HISTORY OF ASP.NET WEB API 6 Preview Versions WCF Web API on CodePlex WCF WebHttp Binding (.NET 4) ASP.NET Web API 4 Release ASP.NET is Open Source ASP.NET Web API 2 Release Candidate ASP.NET Web API (Beta) 30
  • 31. HTTP Messages 101  HTTP is a first class application protocol:  Widely supported across platforms and devices  Scalable  Simple  Uses the request-response messaging pattern  Define resource-based semantics and not RPC (Remote Procedure Call) or methods 31
  • 32. HTTP REQUEST MESSAGES GET http://localhost:2300/api/agents/Bond HTTP/1.1 Accept: text/html, application/xhtml+xml, */* Accept-Language: en-US,en;q=0.7,he;q=0.3 User-Agent: Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; WOW64; Trident/6.0) Accept-Encoding: gzip, deflate Host: localhost:2300 DNT: 1 Connection: Keep-Alive 32
  • 33. HTTP RESPONSE MESSAGES HTTP/1.1 200 OK Cache-Control: public, max-age=300 Content-Type: application/json; charset=utf-8 ETag: "1" Server: Microsoft-IIS/8.0 X-AspNet-Version: 4.0.30319 Date: Mon, 19 Nov 2012 17:49:40 GMT Content-Length: 142 { "Id": "Bond", "FullName": "James Bond", "Alias": "007", "Version": 1, "Image": "http://localhost:2300/api/agents/Bond.jpg" } 33
  • 34. URIS • HTTP is not an RPC protocol • HTTP uses URIs to identify resources over the network • An HTTP URI has the following basic structure: http://theagency.com:8080/agents?id=1 Schema Host Port Absolute Path Query 34
  • 35. CLEAN URLS AND ASP.NET  Using clean URLs can be a problem with IIS  IIS needs extensions to map requests to handlers  Without extensions, IIS is lost  ASP.NET Routing to the rescue with UrlRoutingModule  It’s all about patterns… and mapping them to handlers  The starting point of MVC, Dynamic Data, and Web API  System.Web.Routing.RouteTable.Routes.MapHttpRoute RouteTable.Routes.MapHttpRoute( name: "DefaultApi", routeTemplate: "api/{controller}/{id}", defaults: new { id = RouteParameter.Optional } ); 35
  • 36. ASP.NET WEB API - ROUTING 36
  • 37. Routing with attributes  Why attributes over convention?  Child (sub) resources  Multiple type of parameters or return values  Versioning of actions and controllers  Start by enabling attribute routing  config.MapHttpAttributeRoutes(); [RoutePrefix("api/agents/{agentId}")] public class ObservationsController : ApiController { // GET api/agents/bond/observations [HttpGet("observations/{date}")] public Observation Get(string agentId, DateTime date) { ... } }
  • 38. Verbs • HTTP defines a set of Methods or Verbs that add an action-like semantics to requests • Verbs are defined as the first segment of • the request-line: GET http://localhost:4392/travelers/1 HTTP/1.1 • There are eight verbs defined in HTTP 1.1: GET POST PUT DELETE HEAD OPTIONS TRACE CONNECT 38
  • 39. 3, 2, 1, Actions! • Actions are matched by HTTP verb names and the existence of parameters public class ProductsController : ApiController { public IEnumerable<Product> GetProducts() {...} public Product GetProductById(int id) {...} public HttpResponseMessage PostProduct(Product product) {...} } GET api/products GET api/products/42 POST api/products DELETE api/products/42
  • 40. Status Codes  Status codes describe the result of the server’s effort to satisfy the request  Passed in the response's status-line as three digit alongside a textual description called reason phrase  HTTP has five different categories of status-codes:      1xx – Informational 2xx – Success 3xx – Redirection 4xx – Client Error 5xx – Server Error (100 / 101) (200 – 206) (300 – 307) (400 – 417) (500 – 505)
  • 42.  Returning an HttpResponseMessage allows more control over the response, including:    Status code HTTP headers Entity body public HttpResponseMessage CreateAgent(Agent agent) { agent = _repository.Add(agent); var response = Request.CreateResponse<Agent>(HttpStatusCode.Created, agent); response.Headers.Location = GetAgentLocation(agent.Id); return response; } 42
  • 43. Error Handling • In HTTP services errors are handled by ▫ Returning an appropriate status code ▫ Returning an entity body explaining the error (when applicable) • Web API allows you to handle exceptions by ▫ Return an HttpResponseMessage with appropriate status code (404, 500 …) ▫ Throw an HttpResponseException ▫ Create a general exception handler by using Filters 43
  • 44. HTTP defines a process to best match the server’s response to the client’s expectation  Negotiation can be done using:   Headers: Accept, Accept- Language, Accept- Charset, Accept-Encoding  URI: File extensions (.jpeg, .html), host-name: (com, org), path and query 44
  • 45. ASP.NET, IIS & how to create virtual directory
  • 46. SESSION OBJECTIVES • • • • • • ASP.NET Benefit How Does ASP.NET Work? IIS Creating a Virtual Directory Web Sharing the Project Folder Deleting a Web Project
  • 47. HOW DOES ASP.NET WORK? • Requests an HTML file, the server returns the file • Requests an ASP.NET file, IIS passes the request to the ASP.NET engine on the server • The ASP.NET engine reads the file, line by line, and executes the scripts in the file • ASP.NET file is returned to the browser as plain HTML
  • 48.  Separation of Code from HTML  Graphical Development Environment  Update files while the server is running!  Support for compiled languages  State management
  • 49. IIS – Internet Information Services • Internet Information Service • IIS (Internet Information Services) is Microsoft's Internet server • IIS comes as a free component with Windows servers • IIS is also a part of Windows 2000 and XP Professional
  • 50.     Start, Settings, Control Panel, Administrative Tools, Internet Services Manager Expand node for computer and default Web site Right-click Default Web site icon, select New, Virtual Directory In Virtual Directory Creation Wizard enter your project folder name as the alias and enter the folder and path
  • 51. Web Sharing the Project Folder  Select the Project folder in My Computer  Right-click, select Properties, Web Sharing, activate Share This Folder  In Edit Alias dialog click OK
  • 52. Deleting a Web Project  Project in IIS Virtual Directory  Delete the directory  Project in Web Shared Folder  “Unshare” it from Properties dialog  Either Reboot Computer or Stop and Restart IIS  Delete Folder

Editor's Notes

  1. Additionally supports constraints (type, min/max restriction, regex, and range), optional and default values, ordering, and extensibility.http://www.asp.net/web-api/overview/web-api-routing-and-actions/attribute-routing-in-web-api-2