SlideShare a Scribd company logo
Chapter 2 How ASP.NET Works And slowly, softly, from above the darkness is unfurled A wondrous curtain loosened on the windows of the world. Then suddenly, like magic, ā€¦ Ten thousand lights flash out ā€¦ Alfred Chandler, ā€œLights along the Mile,ā€   The Oxford Book of Australian Verse,  ed. Walter Murdoch, 1918.
Overview ,[object Object],[object Object],[object Object],[object Object]
Event Model ,[object Object],[object Object],[object Object],[object Object],[object Object]
Event Handlers ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],protected void Page_Load(object sender, EventArgs e) { ā€¦ }
ASP.NET Event System ,[object Object],[object Object],[object Object],[object Object]
ASP.NET Event System
Postback ,[object Object],[object Object],[object Object],[object Object]
Postback
Event Types ,[object Object],[object Object],[object Object],[object Object],[object Object]
View State ,[object Object],[object Object],[object Object],<input type=&quot;hidden&quot; name=&quot;__VIEWSTATE&quot; id=&quot;__VIEWSTATE&quot;  value=&quot;/wEPDwUJODExMDE5NzY5D2QWAgIDD2QWAgIBDw8WAh4EVGV4dAUKMDgvMDE vMjAwNmRkZDZPhFHJER4chf3nmlgfL+uq4W58&quot; />
View State ,[object Object],[object Object],[object Object],[object Object]
View State ,[object Object],[object Object],[object Object]
View State ,[object Object],[object Object]
View State ,[object Object],[object Object],[object Object],[object Object]
Page Life Cycle ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Complete Page Life Cycle
Event Handlers ,[object Object],[object Object]
Event Handlers ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],<asp:Button id=&quot;btnSubmit&quot; runat=&quot;server&quot;  OnClick=&quot;btnSubmit_Click&quot;  /> btnSubmit.Click += new EventHandler( this.btnSubmit_Click );
Adding Event Handlers in VS
Event Example Please enter your name: <asp:TextBox ID=&quot;name&quot; runat=&quot;server&quot; /> <br /> Choose favorite author: <asp:DropDownList ID=&quot;myList&quot; runat=&quot;server&quot;> <asp:ListItem>Choose an author</asp:ListItem> <asp:ListItem>Atwood</asp:ListItem> <asp:ListItem>Austin</asp:ListItem> <asp:ListItem>Hawthorne</asp:ListItem> <asp:ListItem>Melville</asp:ListItem> </asp:DropDownList> <br /> <asp:Button ID=&quot;btnEnter&quot; Text=&quot;Enter&quot; runat=&quot;server&quot;  OnClick=&quot;btnEnter_Click&quot;  /> <p><asp:Label ID=&quot;msg1&quot; runat=&quot;server&quot; /></p>
Event Example ā€¦ public partial class EventTest: Page { protected void Page_Load(object sender, EventArgs e) { msg1.Text = &quot;In Page_Load<br/>&quot;; } protected void btnEnter_Click(object sender, EventArgs e) { if (myList.SelectedIndex > 0) { msg1.Text += &quot;Hi &quot; + name.Text + &quot;<br/>&quot;; msg1.Text += &quot;Your favorite author is &quot;; msg1.Text += myList.SelectedItem; } } }
Detecting Postback ,[object Object],[object Object],[object Object]
Detecting Postback ,[object Object],[object Object],protected void Page_Load(object sender, EventArgs e) { ā€¦ if (!  IsPostBack ) { // Do something here for very first request } ā€¦ }
Postback and Non-Postback Controls ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Change Events ,[object Object],[object Object],[object Object]
Using AutoPostBack Choose favorite author: <asp:DropDownList ID=&quot;myList&quot; runat=&quot;server&quot; AutoPostBack=&quot;true&quot;   OnSelectedIndexChanged=&quot;myList_SelectedIndexChanged&quot;  > <asp:ListItem>Choose an author</asp:ListItem> <asp:ListItem>Atwood</asp:ListItem> <asp:ListItem>Austin</asp:ListItem> <asp:ListItem>Hawthorne</asp:ListItem> <asp:ListItem>Melville</asp:ListItem> </asp:DropDownList> <p><asp:Label ID=&quot;msg1&quot; runat=&quot;server&quot; /></p> protected void myList_SelectedIndexChanged(object sender, EventArgs e) { // Ignore first item in list if (myList.SelectedIndex > 0) { msg1.Text += &quot;Hi &quot; + name.Text + &quot;<br/>&quot;; msg1.Text += &quot;Your favorite author is &quot;; msg1.Text += myList.SelectedItem; } }
ASP.NET Behind the Scenes ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
ASP.NET 2.0 Compilation Process
Where is this stuff? ,[object Object],[object Object],[object Object],C:INDOWSicrosoft.NETramework2.0.50727emporary ASP.NET Fileshapter2229f9fdd0746a9.
Page  class ,[object Object]
ASP.NET 2.0 Class Inheritance
Page  class ,[object Object],[object Object],[object Object]
Application Lifecycle ,[object Object]
Application Lifecycle

More Related Content

What's hot

JSP Error handling
JSP Error handlingJSP Error handling
JSP Error handling
kamal kotecha
Ā 
RicoAjaxEngine
RicoAjaxEngineRicoAjaxEngine
RicoAjaxEnginetutorialsruby
Ā 
Ajax and ASP.NET AJAX
Ajax and ASP.NET AJAXAjax and ASP.NET AJAX
Ajax and ASP.NET AJAXJulie Iskander
Ā 
Ajax control tool kit
Ajax control tool kitAjax control tool kit
Ajax control tool kitVidhi Patel
Ā 
Programming web application
Programming web applicationProgramming web application
Programming web applicationaspnet123
Ā 
Programming Server side with Sevlet
 Programming Server side with Sevlet  Programming Server side with Sevlet
Programming Server side with Sevlet backdoor
Ā 
jQuery Ajax
jQuery AjaxjQuery Ajax
jQuery Ajax
Anand Kumar Rajana
Ā 
Introduction to Ajax programming
Introduction to Ajax programmingIntroduction to Ajax programming
Introduction to Ajax programming
Fulvio Corno
Ā 
Html server control - ASP. NET with c#
Html server control - ASP. NET with c#Html server control - ASP. NET with c#
Html server control - ASP. NET with c#
priya Nithya
Ā 
Jquery Ajax
Jquery AjaxJquery Ajax
Jquery Ajax
Anand Kumar Rajana
Ā 
ASP.Net Presentation Part1
ASP.Net Presentation Part1ASP.Net Presentation Part1
ASP.Net Presentation Part1Neeraj Mathur
Ā 
More Asp
More AspMore Asp
More Asp
guest4c97670
Ā 

What's hot (18)

JSP Error handling
JSP Error handlingJSP Error handling
JSP Error handling
Ā 
RicoAjaxEngine
RicoAjaxEngineRicoAjaxEngine
RicoAjaxEngine
Ā 
Ajax and ASP.NET AJAX
Ajax and ASP.NET AJAXAjax and ASP.NET AJAX
Ajax and ASP.NET AJAX
Ā 
Ajax control tool kit
Ajax control tool kitAjax control tool kit
Ajax control tool kit
Ā 
Ajax
AjaxAjax
Ajax
Ā 
Ajax
AjaxAjax
Ajax
Ā 
Programming web application
Programming web applicationProgramming web application
Programming web application
Ā 
Programming Server side with Sevlet
 Programming Server side with Sevlet  Programming Server side with Sevlet
Programming Server side with Sevlet
Ā 
Asp.net.
Asp.net.Asp.net.
Asp.net.
Ā 
jQuery Ajax
jQuery AjaxjQuery Ajax
jQuery Ajax
Ā 
Introduction to Ajax programming
Introduction to Ajax programmingIntroduction to Ajax programming
Introduction to Ajax programming
Ā 
Html server control - ASP. NET with c#
Html server control - ASP. NET with c#Html server control - ASP. NET with c#
Html server control - ASP. NET with c#
Ā 
Jquery Ajax
Jquery AjaxJquery Ajax
Jquery Ajax
Ā 
ASP.Net Presentation Part1
ASP.Net Presentation Part1ASP.Net Presentation Part1
ASP.Net Presentation Part1
Ā 
2310 b 06
2310 b 062310 b 06
2310 b 06
Ā 
Asp
AspAsp
Asp
Ā 
More Asp
More AspMore Asp
More Asp
Ā 
ajax_pdf
ajax_pdfajax_pdf
ajax_pdf
Ā 

Viewers also liked

Big Data World
Big Data WorldBig Data World
Big Data World
Hossein Zahed
Ā 
Entity Framework Overview
Entity Framework OverviewEntity Framework Overview
Entity Framework Overview
ukdpe
Ā 
ASP.NET MVC 5 - EF 6 - VS2015
ASP.NET MVC 5 - EF 6 - VS2015ASP.NET MVC 5 - EF 6 - VS2015
ASP.NET MVC 5 - EF 6 - VS2015
Hossein Zahed
Ā 
HTML & XHTML Basics
HTML & XHTML BasicsHTML & XHTML Basics
HTML & XHTML BasicsHossein Zahed
Ā 
CSharp Language Overview Part 1
CSharp Language Overview Part 1CSharp Language Overview Part 1
CSharp Language Overview Part 1
Hossein Zahed
Ā 
SEO Fundamentals
SEO FundamentalsSEO Fundamentals
SEO Fundamentals
Hossein Zahed
Ā 
Microsoft SQL Server 2008
Microsoft SQL Server 2008Microsoft SQL Server 2008
Microsoft SQL Server 2008Hossein Zahed
Ā 
ASP.NET Page Life Cycle
ASP.NET Page Life CycleASP.NET Page Life Cycle
ASP.NET Page Life Cycle
Abhishek Sur
Ā 
Introduction to angular js for .net developers
Introduction to angular js  for .net developersIntroduction to angular js  for .net developers
Introduction to angular js for .net developers
Mohd Manzoor Ahmed
Ā 
ASP .net MVC
ASP .net MVCASP .net MVC
ASP .net MVC
Divya Sharma
Ā 
Technologies that will disappear in next 5 years
Technologies that will disappear in next 5 yearsTechnologies that will disappear in next 5 years
Technologies that will disappear in next 5 years
Shrey Kapoor
Ā 
Basic c++ programs
Basic c++ programsBasic c++ programs
Basic c++ programs
harman kaur
Ā 
Developing an ASP.NET Web Application
Developing an ASP.NET Web ApplicationDeveloping an ASP.NET Web Application
Developing an ASP.NET Web Application
Rishi Kothari
Ā 
C++ Programming Language
C++ Programming Language C++ Programming Language
C++ Programming Language
Mohamed Loey
Ā 
2008: Web Application Security Tutorial
2008: Web Application Security Tutorial2008: Web Application Security Tutorial
2008: Web Application Security Tutorial
Neil Matatall
Ā 

Viewers also liked (16)

CSS Basics
CSS BasicsCSS Basics
CSS Basics
Ā 
Big Data World
Big Data WorldBig Data World
Big Data World
Ā 
Entity Framework Overview
Entity Framework OverviewEntity Framework Overview
Entity Framework Overview
Ā 
ASP.NET MVC 5 - EF 6 - VS2015
ASP.NET MVC 5 - EF 6 - VS2015ASP.NET MVC 5 - EF 6 - VS2015
ASP.NET MVC 5 - EF 6 - VS2015
Ā 
HTML & XHTML Basics
HTML & XHTML BasicsHTML & XHTML Basics
HTML & XHTML Basics
Ā 
CSharp Language Overview Part 1
CSharp Language Overview Part 1CSharp Language Overview Part 1
CSharp Language Overview Part 1
Ā 
SEO Fundamentals
SEO FundamentalsSEO Fundamentals
SEO Fundamentals
Ā 
Microsoft SQL Server 2008
Microsoft SQL Server 2008Microsoft SQL Server 2008
Microsoft SQL Server 2008
Ā 
ASP.NET Page Life Cycle
ASP.NET Page Life CycleASP.NET Page Life Cycle
ASP.NET Page Life Cycle
Ā 
Introduction to angular js for .net developers
Introduction to angular js  for .net developersIntroduction to angular js  for .net developers
Introduction to angular js for .net developers
Ā 
ASP .net MVC
ASP .net MVCASP .net MVC
ASP .net MVC
Ā 
Technologies that will disappear in next 5 years
Technologies that will disappear in next 5 yearsTechnologies that will disappear in next 5 years
Technologies that will disappear in next 5 years
Ā 
Basic c++ programs
Basic c++ programsBasic c++ programs
Basic c++ programs
Ā 
Developing an ASP.NET Web Application
Developing an ASP.NET Web ApplicationDeveloping an ASP.NET Web Application
Developing an ASP.NET Web Application
Ā 
C++ Programming Language
C++ Programming Language C++ Programming Language
C++ Programming Language
Ā 
2008: Web Application Security Tutorial
2008: Web Application Security Tutorial2008: Web Application Security Tutorial
2008: Web Application Security Tutorial
Ā 

Similar to ASP.NET 02 - How ASP.NET Works

Ajax
AjaxAjax
Ajaxdevisp
Ā 
ASP.NET MVC introduction
ASP.NET MVC introductionASP.NET MVC introduction
ASP.NET MVC introduction
Tomi Juhola
Ā 
Aspnet2 Overview
Aspnet2 OverviewAspnet2 Overview
Aspnet2 Overviewajitbergi
Ā 
2 Asp Dot Net Ajax Extensions
2 Asp Dot Net Ajax Extensions2 Asp Dot Net Ajax Extensions
2 Asp Dot Net Ajax Extensions
Abhishek Bhatnagar
Ā 
AJAX ASP.Net
AJAX ASP.NetAJAX ASP.Net
AJAX ASP.Net
SHC
Ā 
Web forms in ASP.net
Web forms in ASP.netWeb forms in ASP.net
Web forms in ASP.netMadhuri Kavade
Ā 
Event
EventEvent
Event
mussawir20
Ā 
ASP.NET 05 - Exception Handling And Validation Controls
ASP.NET 05 - Exception Handling And Validation ControlsASP.NET 05 - Exception Handling And Validation Controls
ASP.NET 05 - Exception Handling And Validation Controls
Randy Connolly
Ā 
Act as state machine
Act as state machineAct as state machine
Act as state machine
Kiran Chaudhari
Ā 
Web Services Part 2
Web Services Part 2Web Services Part 2
Web Services Part 2patinijava
Ā 
Bronx study jam 2
Bronx study jam 2Bronx study jam 2
Bronx study jam 2
Peter Birdsall
Ā 
Struts2
Struts2Struts2
Struts2
yuvalb
Ā 
Retrofitting
RetrofittingRetrofitting
Retrofitting
Ted Husted
Ā 
Managing states
Managing statesManaging states
Managing states
Paneliya Prince
Ā 
C sharp and asp.net interview questions
C sharp and asp.net interview questionsC sharp and asp.net interview questions
C sharp and asp.net interview questions
Akhil Mittal
Ā 
Esposito Ajax Remote
Esposito Ajax RemoteEsposito Ajax Remote
Esposito Ajax Remoteask bills
Ā 

Similar to ASP.NET 02 - How ASP.NET Works (20)

Vb.Net Web Forms
Vb.Net  Web FormsVb.Net  Web Forms
Vb.Net Web Forms
Ā 
2310 b 05
2310 b 052310 b 05
2310 b 05
Ā 
Ajax
AjaxAjax
Ajax
Ā 
ASP.NET MVC introduction
ASP.NET MVC introductionASP.NET MVC introduction
ASP.NET MVC introduction
Ā 
Aspnet2 Overview
Aspnet2 OverviewAspnet2 Overview
Aspnet2 Overview
Ā 
2 Asp Dot Net Ajax Extensions
2 Asp Dot Net Ajax Extensions2 Asp Dot Net Ajax Extensions
2 Asp Dot Net Ajax Extensions
Ā 
AJAX ASP.Net
AJAX ASP.NetAJAX ASP.Net
AJAX ASP.Net
Ā 
Web forms in ASP.net
Web forms in ASP.netWeb forms in ASP.net
Web forms in ASP.net
Ā 
ASP.NET MVC
ASP.NET MVCASP.NET MVC
ASP.NET MVC
Ā 
Event
EventEvent
Event
Ā 
ASP.NET 05 - Exception Handling And Validation Controls
ASP.NET 05 - Exception Handling And Validation ControlsASP.NET 05 - Exception Handling And Validation Controls
ASP.NET 05 - Exception Handling And Validation Controls
Ā 
Act as state machine
Act as state machineAct as state machine
Act as state machine
Ā 
Web Services Part 2
Web Services Part 2Web Services Part 2
Web Services Part 2
Ā 
Bronx study jam 2
Bronx study jam 2Bronx study jam 2
Bronx study jam 2
Ā 
Struts2
Struts2Struts2
Struts2
Ā 
Retrofitting
RetrofittingRetrofitting
Retrofitting
Ā 
Managing states
Managing statesManaging states
Managing states
Ā 
C sharp and asp.net interview questions
C sharp and asp.net interview questionsC sharp and asp.net interview questions
C sharp and asp.net interview questions
Ā 
Esposito Ajax Remote
Esposito Ajax RemoteEsposito Ajax Remote
Esposito Ajax Remote
Ā 
Ridingapachecamel
RidingapachecamelRidingapachecamel
Ridingapachecamel
Ā 

More from Randy Connolly

Celebrating the Release of Computing Careers and Disciplines
Celebrating the Release of Computing Careers and DisciplinesCelebrating the Release of Computing Careers and Disciplines
Celebrating the Release of Computing Careers and Disciplines
Randy Connolly
Ā 
Public Computing Intellectuals in the Age of AI Crisis
Public Computing Intellectuals in the Age of AI CrisisPublic Computing Intellectuals in the Age of AI Crisis
Public Computing Intellectuals in the Age of AI Crisis
Randy Connolly
Ā 
Why Computing Belongs Within the Social Sciences
Why Computing Belongs Within the Social SciencesWhy Computing Belongs Within the Social Sciences
Why Computing Belongs Within the Social Sciences
Randy Connolly
Ā 
Ten-Year Anniversary of our CIS Degree
Ten-Year Anniversary of our CIS DegreeTen-Year Anniversary of our CIS Degree
Ten-Year Anniversary of our CIS Degree
Randy Connolly
Ā 
Careers in Computing (2019 Edition)
Careers in Computing (2019 Edition)Careers in Computing (2019 Edition)
Careers in Computing (2019 Edition)
Randy Connolly
Ā 
Facing Backwards While Stumbling Forwards: The Future of Teaching Web Develop...
Facing Backwards While Stumbling Forwards: The Future of Teaching Web Develop...Facing Backwards While Stumbling Forwards: The Future of Teaching Web Develop...
Facing Backwards While Stumbling Forwards: The Future of Teaching Web Develop...
Randy Connolly
Ā 
Where is the Internet? (2019 Edition)
Where is the Internet? (2019 Edition)Where is the Internet? (2019 Edition)
Where is the Internet? (2019 Edition)
Randy Connolly
Ā 
Modern Web Development (2018)
Modern Web Development (2018)Modern Web Development (2018)
Modern Web Development (2018)
Randy Connolly
Ā 
Helping Prospective Students Understand the Computing Disciplines
Helping Prospective Students Understand the Computing DisciplinesHelping Prospective Students Understand the Computing Disciplines
Helping Prospective Students Understand the Computing Disciplines
Randy Connolly
Ā 
Constructing a Web Development Textbook
Constructing a Web Development TextbookConstructing a Web Development Textbook
Constructing a Web Development Textbook
Randy Connolly
Ā 
Web Development for Managers
Web Development for ManagersWeb Development for Managers
Web Development for Managers
Randy Connolly
Ā 
Disrupting the Discourse of the "Digital Disruption of _____"
Disrupting the Discourse of the "Digital Disruption of _____"Disrupting the Discourse of the "Digital Disruption of _____"
Disrupting the Discourse of the "Digital Disruption of _____"
Randy Connolly
Ā 
17 Ways to Fail Your Courses
17 Ways to Fail Your Courses17 Ways to Fail Your Courses
17 Ways to Fail Your Courses
Randy Connolly
Ā 
Red Fish Blue Fish: Reexamining Student Understanding of the Computing Discip...
Red Fish Blue Fish: Reexamining Student Understanding of the Computing Discip...Red Fish Blue Fish: Reexamining Student Understanding of the Computing Discip...
Red Fish Blue Fish: Reexamining Student Understanding of the Computing Discip...
Randy Connolly
Ā 
Constructing and revising a web development textbook
Constructing and revising a web development textbookConstructing and revising a web development textbook
Constructing and revising a web development textbook
Randy Connolly
Ā 
Computing is Not a Rock Band: Student Understanding of the Computing Disciplines
Computing is Not a Rock Band: Student Understanding of the Computing DisciplinesComputing is Not a Rock Band: Student Understanding of the Computing Disciplines
Computing is Not a Rock Band: Student Understanding of the Computing Disciplines
Randy Connolly
Ā 
Citizenship: How do leaders in universities think about and experience citize...
Citizenship: How do leaders in universities think about and experience citize...Citizenship: How do leaders in universities think about and experience citize...
Citizenship: How do leaders in universities think about and experience citize...
Randy Connolly
Ā 
Thinking About Technology
Thinking About TechnologyThinking About Technology
Thinking About Technology
Randy Connolly
Ā 
A longitudinal examination of SIGITE conference submission data
A longitudinal examination of SIGITE conference submission dataA longitudinal examination of SIGITE conference submission data
A longitudinal examination of SIGITE conference submission data
Randy Connolly
Ā 
Web Security
Web SecurityWeb Security
Web Security
Randy Connolly
Ā 

More from Randy Connolly (20)

Celebrating the Release of Computing Careers and Disciplines
Celebrating the Release of Computing Careers and DisciplinesCelebrating the Release of Computing Careers and Disciplines
Celebrating the Release of Computing Careers and Disciplines
Ā 
Public Computing Intellectuals in the Age of AI Crisis
Public Computing Intellectuals in the Age of AI CrisisPublic Computing Intellectuals in the Age of AI Crisis
Public Computing Intellectuals in the Age of AI Crisis
Ā 
Why Computing Belongs Within the Social Sciences
Why Computing Belongs Within the Social SciencesWhy Computing Belongs Within the Social Sciences
Why Computing Belongs Within the Social Sciences
Ā 
Ten-Year Anniversary of our CIS Degree
Ten-Year Anniversary of our CIS DegreeTen-Year Anniversary of our CIS Degree
Ten-Year Anniversary of our CIS Degree
Ā 
Careers in Computing (2019 Edition)
Careers in Computing (2019 Edition)Careers in Computing (2019 Edition)
Careers in Computing (2019 Edition)
Ā 
Facing Backwards While Stumbling Forwards: The Future of Teaching Web Develop...
Facing Backwards While Stumbling Forwards: The Future of Teaching Web Develop...Facing Backwards While Stumbling Forwards: The Future of Teaching Web Develop...
Facing Backwards While Stumbling Forwards: The Future of Teaching Web Develop...
Ā 
Where is the Internet? (2019 Edition)
Where is the Internet? (2019 Edition)Where is the Internet? (2019 Edition)
Where is the Internet? (2019 Edition)
Ā 
Modern Web Development (2018)
Modern Web Development (2018)Modern Web Development (2018)
Modern Web Development (2018)
Ā 
Helping Prospective Students Understand the Computing Disciplines
Helping Prospective Students Understand the Computing DisciplinesHelping Prospective Students Understand the Computing Disciplines
Helping Prospective Students Understand the Computing Disciplines
Ā 
Constructing a Web Development Textbook
Constructing a Web Development TextbookConstructing a Web Development Textbook
Constructing a Web Development Textbook
Ā 
Web Development for Managers
Web Development for ManagersWeb Development for Managers
Web Development for Managers
Ā 
Disrupting the Discourse of the "Digital Disruption of _____"
Disrupting the Discourse of the "Digital Disruption of _____"Disrupting the Discourse of the "Digital Disruption of _____"
Disrupting the Discourse of the "Digital Disruption of _____"
Ā 
17 Ways to Fail Your Courses
17 Ways to Fail Your Courses17 Ways to Fail Your Courses
17 Ways to Fail Your Courses
Ā 
Red Fish Blue Fish: Reexamining Student Understanding of the Computing Discip...
Red Fish Blue Fish: Reexamining Student Understanding of the Computing Discip...Red Fish Blue Fish: Reexamining Student Understanding of the Computing Discip...
Red Fish Blue Fish: Reexamining Student Understanding of the Computing Discip...
Ā 
Constructing and revising a web development textbook
Constructing and revising a web development textbookConstructing and revising a web development textbook
Constructing and revising a web development textbook
Ā 
Computing is Not a Rock Band: Student Understanding of the Computing Disciplines
Computing is Not a Rock Band: Student Understanding of the Computing DisciplinesComputing is Not a Rock Band: Student Understanding of the Computing Disciplines
Computing is Not a Rock Band: Student Understanding of the Computing Disciplines
Ā 
Citizenship: How do leaders in universities think about and experience citize...
Citizenship: How do leaders in universities think about and experience citize...Citizenship: How do leaders in universities think about and experience citize...
Citizenship: How do leaders in universities think about and experience citize...
Ā 
Thinking About Technology
Thinking About TechnologyThinking About Technology
Thinking About Technology
Ā 
A longitudinal examination of SIGITE conference submission data
A longitudinal examination of SIGITE conference submission dataA longitudinal examination of SIGITE conference submission data
A longitudinal examination of SIGITE conference submission data
Ā 
Web Security
Web SecurityWeb Security
Web Security
Ā 

Recently uploaded

Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
Ā 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Albert Hoitingh
Ā 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
Guy Korland
Ā 
Dev Dives: Train smarter, not harder ā€“ active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder ā€“ active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder ā€“ active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder ā€“ active learning and UiPath LLMs for do...
UiPathCommunity
Ā 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Thierry Lestable
Ā 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
ControlCase
Ā 
UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3
DianaGray10
Ā 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
Ā 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Product School
Ā 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
Elena Simperl
Ā 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
Dorra BARTAGUIZ
Ā 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
Ā 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Inflectra
Ā 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
Product School
Ā 
Monitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR EventsMonitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR Events
Ana-Maria Mihalceanu
Ā 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
Ā 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
Elena Simperl
Ā 
Generating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using SmithyGenerating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using Smithy
g2nightmarescribd
Ā 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Product School
Ā 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
Ā 

Recently uploaded (20)

Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Ā 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Ā 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
Ā 
Dev Dives: Train smarter, not harder ā€“ active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder ā€“ active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder ā€“ active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder ā€“ active learning and UiPath LLMs for do...
Ā 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Ā 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
Ā 
UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3
Ā 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Ā 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Ā 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
Ā 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
Ā 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Ā 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Ā 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
Ā 
Monitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR EventsMonitoring Java Application Security with JDK Tools and JFR Events
Monitoring Java Application Security with JDK Tools and JFR Events
Ā 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
Ā 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
Ā 
Generating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using SmithyGenerating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using Smithy
Ā 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Ā 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
Ā 

ASP.NET 02 - How ASP.NET Works

  • 1. Chapter 2 How ASP.NET Works And slowly, softly, from above the darkness is unfurled A wondrous curtain loosened on the windows of the world. Then suddenly, like magic, ā€¦ Ten thousand lights flash out ā€¦ Alfred Chandler, ā€œLights along the Mile,ā€ The Oxford Book of Australian Verse, ed. Walter Murdoch, 1918.
  • 2.
  • 3.
  • 4.
  • 5.
  • 7.
  • 9.
  • 10.
  • 11.
  • 12.
  • 13.
  • 14.
  • 15.
  • 17.
  • 18.
  • 20. Event Example Please enter your name: <asp:TextBox ID=&quot;name&quot; runat=&quot;server&quot; /> <br /> Choose favorite author: <asp:DropDownList ID=&quot;myList&quot; runat=&quot;server&quot;> <asp:ListItem>Choose an author</asp:ListItem> <asp:ListItem>Atwood</asp:ListItem> <asp:ListItem>Austin</asp:ListItem> <asp:ListItem>Hawthorne</asp:ListItem> <asp:ListItem>Melville</asp:ListItem> </asp:DropDownList> <br /> <asp:Button ID=&quot;btnEnter&quot; Text=&quot;Enter&quot; runat=&quot;server&quot; OnClick=&quot;btnEnter_Click&quot; /> <p><asp:Label ID=&quot;msg1&quot; runat=&quot;server&quot; /></p>
  • 21. Event Example ā€¦ public partial class EventTest: Page { protected void Page_Load(object sender, EventArgs e) { msg1.Text = &quot;In Page_Load<br/>&quot;; } protected void btnEnter_Click(object sender, EventArgs e) { if (myList.SelectedIndex > 0) { msg1.Text += &quot;Hi &quot; + name.Text + &quot;<br/>&quot;; msg1.Text += &quot;Your favorite author is &quot;; msg1.Text += myList.SelectedItem; } } }
  • 22.
  • 23.
  • 24.
  • 25.
  • 26. Using AutoPostBack Choose favorite author: <asp:DropDownList ID=&quot;myList&quot; runat=&quot;server&quot; AutoPostBack=&quot;true&quot; OnSelectedIndexChanged=&quot;myList_SelectedIndexChanged&quot; > <asp:ListItem>Choose an author</asp:ListItem> <asp:ListItem>Atwood</asp:ListItem> <asp:ListItem>Austin</asp:ListItem> <asp:ListItem>Hawthorne</asp:ListItem> <asp:ListItem>Melville</asp:ListItem> </asp:DropDownList> <p><asp:Label ID=&quot;msg1&quot; runat=&quot;server&quot; /></p> protected void myList_SelectedIndexChanged(object sender, EventArgs e) { // Ignore first item in list if (myList.SelectedIndex > 0) { msg1.Text += &quot;Hi &quot; + name.Text + &quot;<br/>&quot;; msg1.Text += &quot;Your favorite author is &quot;; msg1.Text += myList.SelectedItem; } }
  • 27.
  • 29.
  • 30.
  • 31. ASP.NET 2.0 Class Inheritance
  • 32.
  • 33.