Download presentation
Presentation is loading. Please wait.
1
Current Popular IT I Pertemuan 11
Matakuliah : T0403/Current Popular IT I Tahun : 2008 Current Popular IT I Pertemuan 11
2
Learning Outcomes Learner can choose options to make custom controls
Learner can make custom controls Learner can make user controls Copyright © Surya Sujarwo 2008 Bina Nusantara
3
Material Outline Creating custom controls with user controls
Building custom controls Encapsulating Functionality in ASP.NET WebControl base class and control styles Server Control Events Server Control Templates Building Components Embedding and Creating Databound Controls Server Control Data Binding Building Templated Databounds Control Copyright © Surya Sujarwo 2008 Bina Nusantara
4
Creating custom controls with user controls
References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
5
Creating custom controls with user controls (Continue…)
References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
6
Creating custom controls with user controls (Continue…)
References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
7
Building custom controls
To build basic control, the control can inherits from: System.Web.UI.Control System.Web.UI.WebControls.WebControl System.Web.UI.WebControls.CompositeControl Control: References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
8
Building custom controls (Continue…)
References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
9
Building custom controls (Continue…)
WebControl: References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
10
Building custom controls (Continue…)
References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
11
Building custom controls (Continue…)
Composite Control References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
12
Building custom controls (Continue…)
References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
13
Encapsulating Functionality in ASP.NET
Packaging Content in ASP.NET Two options: user controls, custom server controls Inheritance Encapsulation References: ProASP.NET 3.5 Server Controls and AJAX Components(Rob Cameron and Dale Michalk, 2008) Bina Nusantara
14
WebControl base class and control styles
Styling using tag Styling using css WebControls’ ControlStyle Style Property CSS Property BackColor background-color BorderColor border-color BorderStyle border-style BorderWidth border-width CssClass CSS class name Font font weight, style, family, and so on Style Property CSS Property ForeColor color Height Width References: ProASP.NET 3.5 Server Controls and AJAX Components(Rob Cameron and Dale Michalk, 2008) Bina Nusantara
15
Server Control Events References: ProASP.NET 3.5 Server Controls and AJAX Components(Rob Cameron and Dale Michalk, 2008) Bina Nusantara
16
Server Control Events (Continue…)
References: ProASP.NET 3.5 Server Controls and AJAX Components(Rob Cameron and Dale Michalk, 2008) Bina Nusantara
17
Server Control Templates
References: ProASP.NET 3.5 Server Controls and AJAX Components(Rob Cameron and Dale Michalk, 2008) Bina Nusantara
18
Server Control Templates (Continue…)
References: ProASP.NET 3.5 Server Controls and AJAX Components(Rob Cameron and Dale Michalk, 2008) Bina Nusantara
19
Embedding and Creating Databound Controls
References: Pro ASP.NET for SQL Server (Brennan Stehling, 2007) Bina Nusantara
20
Server Control Data Binding
References: ProASP.NET 3.5 Server Controls and AJAX Components(Rob Cameron and Dale Michalk, 2008) Bina Nusantara
21
Building Templated Databounds Control
Implement ITemplate Interface References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
22
Building Templated Databounds Control (Continue…)
References: ASP.NET 3.5 Unleashed (Stephen Walther, 2008) Bina Nusantara
23
Writing optimized data access code
NAMESPACE DESCRIPTION System.Data Provides base classes for ADO.NET, focused on the DataSet class and its child classes, such as DataRow, DataColumn, and DataRelation. System.Data.SqlClient The SQL Server .NET data provider. System.Data.OleDb The OLE DB .NET data provider. System.Data.Common Provides classes that are shared by all .NET data providers. Many of these classes are abstract and may be used to create custom data providers. System.Data.SqlTypes Provides classes for native data types in SQL Server. System.Xml Provides classes for processing XML. System.Xml.Schema Provides classes for processing XML Schema Definition (XSD) schema files. System.Xml.Xsl Provides classes for processing Extensible Stylesheet Transformation (XSLT) transforms. References: Performance Tuning and Optimizing ASP.NET Applications (Jeffrey Hasan and Kenneth Tu, 2003) Bina Nusantara
24
That’s All Thank You for the Attention
Bina Nusantara
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.