Asp.NET Core Server Controls. Slide 2 Lecture Overview Understanding the types of ASP.NET controls HTML controls ASP.NET (Web) controls.

Slides:



Advertisements
Similar presentations
Unit 02. ASP.NET Introduction HTML & Server controls Postbacks Page Lifecycle.
Advertisements

IT533 Lecture ASP.NET Controls. Installations Microsoft® SQL Server® 2008 Express.
Working with ASP Pages. Slide 2 The Tag (1) Remember that most ASP.NET pages contain a single tag with the runat attribute set It’s possible to have multiple.
Asp.NET Core Server Controls. Slide 2 Lecture Overview Understanding the types of ASP.NET controls HTML controls ASP.NET (Web) controls.
Anatomy of an ASP.NET Page. Slide 2 My Version of the Big Picture (1) ASP Worker (Engine) Your application Runs Server Other applications User 1User 2.
COS 381 Day 23. © 2006 Pearson Addison-Wesley. All rights reserved Agenda Capstone progress report Overdue –Only received 1 out of 6 Capstone projects.
Web Development Using ASP.NET CA – 240 Kashif Jalal Welcome to week – 3-1 of…
Introduction to ASP.NET, Second Edition2 Chapter Objectives.
Introduction to ASP.NET
Web Development & Design Foundations with XHTML Chapter 9 Key Concepts.
ASP.NET Programming with C# and SQL Server First Edition
Chapter 9 Collecting Data with Forms. A form on a web page consists of form objects such as text boxes or radio buttons into which users type information.
Overview This presentation covers the initial overview of the different server controls. 2.
1 Web Developer & Design Foundations with XHTML Chapter 6 Key Concepts.
Introduction to.Net and ASP.Net Course Introduction Build Your Own ASP.Net Website: Chapter 1 Microsoft ASP.Net Walkthrough: Creating a Basic Web Forms.
Tutorial: Introduction to ASP.NET Internet Technologies and Web Application 4 th February 2010.
1 CS 3870/CS 5870 Static and Dynamic Web Pages ASP.NET and IIS.
Database-Driven Web Sites, Second Edition1 Chapter 8 Processing ASP.NET Web Forms and Working With Server Controls.
Chapter 3 Using Validation Controls. What is a Validation Control? A control that validates the value in another control Renders as an HTML tag with an.
Dr. Azeddine Chikh IS444: Modern tools for applications development.
Object-Oriented Application Development Using VB.NET 1 Chapter 12 Web Forms, HTML, and ASP.NET.
HTML, GUI, ASP.NET Rina Zviel-Girshin Lecture 2
Joe Hummel, PhD Dept of Mathematics and Computer Science Lake Forest College
Overview of Previous Lesson(s) Over View  Server controls are small building blocks of the graphical user interface, which includes  Text boxes  Buttons.
.Net is a collection of libraries, templates and services designed to make programming applications of all kinds, easier, more flexible (multi platform),
Overview of Previous Lesson(s) Over View  ASP.NET Pages  Modular in nature and divided into the core sections  Page directives  Code Section  Page.
Beginning Web Site Development Module 1 – Dynamic Web Site Development Fundamentals of building dynamic Web sites with ASP.NET 2.0 and C# Version.
ASP.Net Web Applications. Characteristics of a typical data driven web application Web Server HTML Graphics Active-X Java Applets HTTP Request ADO / JDBC.
Web Development Using ASP.NET CA – 240 Kashif Jalal Welcome to week – 4-1 of…
Web Application and Development Digital Media Department Unit Credit Value : 4 Essential Learning time : 120 hours Digital Media.
ASP.NET Web Server Controls Basic Web Server Controls.
Web Controls Chapter-7. Page  2 Synopsis  Stepping Up to Web controls  Basic Web control classes  Web control classes  Web control Base class  Units,
© Minder Chen, ASP.NET 2.0: Introduction - 1 ASP.NET 2.0 Minder Chen, Ph.D. Framework Base Class Library ADO.NET: Data & XML.
Chapter 4 – Working with ASP.NET Controls Dr. Stephanos Mavromoustakos.
ASP.NET Controls. Slide 2 Lecture Overview Identify the types of controls supported by ASP.NET and the differences between them.
Tutorial 7 Creating Forms. Objectives Session 7.1 – Create an HTML form – Insert fields for text – Add labels for form elements – Create radio buttons.
ASP.NET.. ASP.NET Environment ASP.NET is Microsoft's programming framework that enables the development of Web applications and services. It is an easy.
© 2010 Delmar, Cengage Learning Chapter 8 Collecting Data with Forms.
 2008 Pearson Education, Inc. All rights reserved Introduction to XHTML.
Web Development & Design Foundations with XHTML Chapter 9 Key Concepts.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 Unit 3: Adding Code to a Microsoft ASP.NET Web Form.
Overview of Previous Lesson(s) Over View  SDI programs  The Application Wizard can generate single-document interface (SDI) applications that work.
JavaScript - A Web Script Language Fred Durao
Anatomy of an ASP.NET Page. Slide 2 Compiling an ASP.NET Page An ASP.NET page is compiled when it is rendered for the first time A page is compiled to.
Things like Textboxes, Lables, ‘n’at. ASPX page is not HTML Controls are rendered into markup that a browser can understand Some controls are rendered.
Module 1: Working with ASP.NET. Overview Introducing ASP.NET Creating Web Forms Adding ASP.NET Code to a Page Handling Page Events Discussion: ASP vs.
Chapter 4: Working with ASP.NET Server Controls OUTLINE  What ASP.NET Server Controls are  How the ASP.NET run time processes the server controls on.
HTML Forms. Slide 2 Forms (Introduction) The purpose of input forms Organizing forms with a and Using different element types to get user input A brief.
TRAINING SESSIONS.NET Controls.  Standard Controls  Label  Textbox  Checkbox  Button, Image Button, Image control  Radio Button  Literal  Hyperlink.
ASP.Net, Web Forms and Web Controls 1 Outline Session Tracking Cookies Session Tracking with HttpSessionState.
ASP.NET 4 Unleashed Chapter 1. .aspx page: contains C# script and HTML code including tags. Listing 1.1 FirstPage.aspx.
Overview of Previous Lesson(s) Over View  ASP is a technology that enables scripts in web pages to be executed by an Internet server.  ASP.NET is a.
Internet & World Wide Web How to Program, 5/e Copyright © Pearson, Inc All Rights Reserved.
PostBack  When an initial request for a page (a Web Form) is received by ASP.NET, it locates and loads the requested Web Form (and if necessary compiles.
1 Introduction to Web Application Review. 2 Five Layers Architecture HTML, CSS, Java Script ASP.net User ’ s.dll, Nunit, Web Services ADO.net SQL Server,
Event Handling & Viewstate CS 351 Ed Gellenbeck. Today Review of Web Forms ASP.NET Object Hierarchy Events State Management Page State Session State Application.
 ASP.NET provides an event based programming model that simplifies web programming  All GUI applications are incomplete without enabling actions  These.
1 Introducing Web Developer Tools Rapid application development tools ASP.NET-compatible web editors –Visual Studio.NET Professional Edition –Visual Studio.
XHTML Forms.
Computing with C# and the .NET Framework
ASP.NET Forms.
Working with ASP.NET Server Controls
Web Application Web Application are programs that can be executed either on a Web server or in a Web browser. An Online store accessed through a browser.
Web Forms, HTML, and ASP.NET
Chapter 8 User Controls.
© 2016, Mike Murach & Associates, Inc.
Anatomy of an ASP.NET Page
Static and Dynamic Web Pages
ASP.NET.
Web Development Using ASP .NET
Presentation transcript:

Asp.NET Core Server Controls

Slide 2 Lecture Overview Understanding the types of ASP.NET controls HTML controls ASP.NET (Web) controls

Slide 3 The runat Attribute The runat attribute makes a server control a server control This is true for both HTML and Web controls All tags without the runat attribute set are copied verbatim to the output stream (HTTP response)

Slide 4 Categorizing Server Controls ASP.NET CONTROLS HTML CONTROLS WEB CONTROLS

Slide 5 Categorizing Server Controls HTML controls always map to HTML tags All attributes are strictly compatible with XHTML They allow you to perform ‘some’ server side processing Web Controls (ASP.NET server controls) Are implemented by the ASP server as.NET Framework classes having a common.NET programming interface

Slide 6 Generalities HTML controls and Web controls can sometimes to do the same thing HTML controls can be used to conditionally create client-side script Web controls generally provide a ‘richer’ programmatic interface

Slide 7 HTML Controls (Example ) A tag can be designated runat=“server” The Header property maps to the HTML tag

Slide 8 HTML Controls (Example ) Store a value in the page header protected void Page_Load(object sender, EventArgs e) { Header.Title = "IS 460 HTML Control Demo " + System.DateTime.Now.ToString(); }

Slide 9 HTML Controls (Example ) The following tag is emitted from the server-side control IS 460 HTML Control Demo 9/7/ :09:10 PM

Slide 10 HTML Controls The HTMLAnchor class implements tags tags designated runat=“server” and having an id will be seen by the server

Slide 11 ASP.NET Server Controls These are unique to ASP.NET All are contained in the System.Web.UI.WebControls namespace All derive from WebControl runat=“server” attribute is required or the markup will be rendered verbatim They are not the same as HTML controls The programming interface is more intuitive

Slide 12 ASP.NET Server Controls (Properties 1) ID – Name that will be used to reference the control instance programmatically Page – Page object on which the control resides Parent – parent control instance Visible – Make the control instance visible or invisible EnableViewState defines whether contents are persisted through view state

Slide 13 ASP.Net Server Controls (Properties 2) The Style property contains references a collection of CSS style MyControlStyle[“border-color”] = blue; The CssClass contains the name of a defined CSS class txtStyleDemo1.CssClass = "TextBox"

Slide 14 ASP.NET Server Controls (Methods) Focus – sets input focus to the control instance when it is rendered HasControls – denotes whether this control instance has child controls Controls – a collection of child controls DataBind – binds the control instance to a data source

Slide 15 ASP.NET Server Controls (Events) Same page and control events discussed in the previous chapter Init – First step in the life cycle Load – occurs when the control is loaded into the page PreRender – fires just before the page is rendered Unload – control has been rendered. Use only to close files or release connections

Slide 16 Other Control Characteristics Adaptive rendering allows controls to render differently based on the browser Control properties can be declared for different browsers, as follows:

Slide 17 Control State (Introduction) State information must often be persisted across page requests Control state is like view state You generally don’t mess with the control state

Slide 18 Core Web Controls (Introduction) Editable controls include check boxes, radio buttons, text boxes, labels, etc… There is a Table control that implements a table container TableCell and TableRow implement cells and rows See Demo HyperLink and LinkButton implement links Use the FileUpload control to upload files

Slide 19 Button Controls (Introduction) CausesValidation determines whether a validation is performed when the button is clicked. ValidationGroup also controls validation More next time Text contains the text that appears in the button Visible property displays or hides the button

Slide 20 Other Controls The Panel control acts as a container for other controls The View control creates a group of interchangeable panels