Building Applications using ASP.NET and C# / Session 15 / 1 of 17 Sessio n 15.

Slides:



Advertisements
Similar presentations
PHP Form and File Handling
Advertisements

ASP.NET Best Practices Dawit Wubshet Park University.
Chapter 31 Basic Form-Processing Techniques JavaServer Pages By Xue Bai.
Caching MacDonald Ch. 26 MIS 424 MIS 424 Professor Sandvig Professor Sandvig.
Chapter 1: An Introduction To ASP.NET Web Programming
Using Session Control in PHP tMyn1 Using Session Control in PHP HTTP is a stateless protocol, which means that the protocol has no built-in way of maintaining.
Microsoft ® Official Course Monitoring and Troubleshooting Custom SharePoint Solutions SharePoint Practice Microsoft SharePoint 2013.
Christopher M. Pascucci Basic Structural Concepts of.NET Browser – Server Interaction.
IT533 Lectures Configuring, Deploying, Tracing and Error Handling.
Form Handling, Validation and Functions. Form Handling Forms are a graphical user interfaces (GUIs) that enables the interaction between users and servers.
CS603 Microsoft.NET April 8, What is.NET? Language for distributed computation –C#, VB.NET, JScript Protocols –SOAP, HTTP Run-time environment –Common.
Tutorial: Introduction to ASP.NET Internet Technologies and Web Application 4 th February 2010.
Joe Hummel, PhD Dept of Mathematics and Computer Science Lake Forest College
MSIS 5133 Advanced MIS - E-Commerce Spring 2003 Lecture 4: DotNet Technologies - Part 5 Developing Applications – Part 1 Dr. Rathindra Sarathy.
Overview of Previous Lesson(s) Over View  Server controls are small building blocks of the graphical user interface, which includes  Text boxes  Buttons.
Overview of Previous Lesson(s) Over View  ASP.NET Pages  Modular in nature and divided into the core sections  Page directives  Code Section  Page.
Welcome  30 Question & 30 Minutes  Question Will Move Automatically After 1 Min Your Exam Start Now Lecturer : Zalak Thakrar.
Beginning Web Site Development Module 1 – Dynamic Web Site Development Fundamentals of building dynamic Web sites with ASP.NET 2.0 and C# Version.
Chapter 71 Building Data-Driven ASP.NET Applications Introduction to ASP.NET By Kathleen Kalata.
ASP Hello, world. ServerClient Response Request A form.
ASP.NET Web Server Controls Basic Web Server Controls.
1 ASP.NET ASP.NET Rina Zviel-Girshin Lecture 4. 2 Overview Data Binding Data Providers Data Connection Data Manipulations.
CIS 375—Web App Dev II ASP.NET 10 Database 2. 2 Introduction to Server-Side Data Server-side data access is unique in that Web pages are basically ___________.
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.
Tracing 1www.tech.findforinfo.com. Contents Why Tracing Why Tracing Tracing in ASP.NET Tracing in ASP.NET Page Level tracing Page Level tracing Application.
1 Maryland ColdFusion User Group Session Management December 2001 Michael Schuler
Caching Chapter 12. Caching For high-performance apps Caching: storing frequently-used items in memory –Accessed more quickly Cached Web Form bypasses:
1 CS 3870/CS 5870 Note04 Session Variables and Post Back.
Effective Security in ASP.Net Applications Jatin Sharma: Summer 2005.
Christopher M. Pascucci Basic Structural Concepts of.NET Managing State & Scope.
ASP.NET Rina Zviel-Girshin Lecture 5
Global.asax file. Agenda What is Global.asax file How to add the Global.asax file What are the default events available Explanation to Application_Level.
Session and Cookie Management in.Net Sandeep Kiran Shiva UIN:
ASP.NET OPTIMIZATION. Why Optimize? $$$ Whether you build applications for customers or not, enhanced applications save money.
ASP.NET Caching - Pradeepa Chandramohan. What is Caching? Storing data in memory for quick access. In Web Application environment, data that is cached.
Module 7: Creating a Microsoft ASP.NET Web Application.
Website Security ISYS 512. Authentication Authentication is the process that determines the identity of a user.
COOKIES and SESSIONS. COOKIES A cookie is often used to identify a user. A cookie is a small file that the server embeds on the user's computer. Each.
State Management. Content State Management View State Cross-Page Posting Query String Cookies Session State Application State Muzaffer DOĞAN - Anadolu.
Web Database Programming Week 7 Session Management & Authentication.
PAGE DIRECTIVES. Page Directives  They are instructions, inserted at the top of an ASP.NET page, to control the behavior of ASP.NET pages.  So it is.
ASP.Net, Web Forms and Web Controls 1 Outline Session Tracking Cookies Session Tracking with HttpSessionState.
The Problem of State. We will look at… Sometimes web development is just plain weird! Internet / World Wide Web Aspects of their operation The role of.
ASP.net Form State Jeremy Boyd, Senior Technical Lead - Intergen MSDN Regional Director – New Zealand.
Understanding Web Applications Lesson 4. Objective Domain Matrix Skills/ConceptsMTA Exam Objectives Understanding Web Page Development Understand Web.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
Working With ASP.NET Application. Create a new virtual directory The procedure to create a new virtual directory Internet Services Manager Right click.
Building Applications using ASP.NET and C# / Session 5 / 1 of 19 Session 5.
Asp.NET Core Server Controls. Slide 2 Lecture Overview Understanding the types of ASP.NET controls HTML controls ASP.NET (Web) controls.
2314 – Programming Language Concepts Introduction to ADO.NET.
 A cookie is often used to identify a user. A cookie is a small file that the server embeds on the user's computer. Each time the same computer requests.
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.
Module 6: Administering Reporting Services. Overview Server Administration Performance and Reliability Monitoring Database Administration Security Administration.
Text INTRODUCTION TO ASP.NET. InterComm Campaign Guidelines CONFIDENTIAL Simply Server side language Simplified page development model Modular, well-factored,
Module 5: Using Trace in Microsoft ASP.NET Pages.
Web Page Designing With Dreamweaver MX\Session 1\1 of 9 Session 3 PHP Advanced.
PLACING ORDERS- SHOPPPING CARTS. Introduction There are several stages to the order process, starting with an order page, which allows customers to add.
Introduction to ASP.NET, Second Edition2 Chapter Objectives.
ASP.NET State Management Overview Prepared By Manish Kumar Aery(IM66) Department of computer Application IET Bhaddal (Ropar)
Session Variables and Post Back
Chapter 8 User Controls.
Data Virtualization Tutorial… CORS and CIS
Invoking Java Code from JSP
Session management.
ASP.NET 4.0 State Management Improvements – Deep Dive
Active server pages (ASP.NET)
Knowledge Byte In this section, you will learn about:
© 2016, Mike Murach & Associates, Inc.
5/6/2019 Session 8.2 Postback, ViewState
Caching.
Presentation transcript:

Building Applications using ASP.NET and C# / Session 15 / 1 of 17 Sessio n 15

Building Applications using ASP.NET and C# / Session 15 / 2 of 17 Session Objectives Debug ASP.net application Output Caching Trace ASP.net application Data Caching Explain Deploy Caching into applications

Building Applications using ASP.NET and C# / Session 15 / 3 of 17 TracingTracing

Building Applications using ASP.NET and C# / Session 15 / 4 of 17 Page Level Tracing Testing Trace... Request Information

Building Applications using ASP.NET and C# / Session 15 / 5 of 17 Trace Information Categories Category Description Request DetailsLists all the information of the request Trace InformationLists information from standard and custom trace statements Control TreeLists all of the items in the page Cookies CollectionLists all of the cookies of the page with their values Header CollectionLists all the items of the HTTP header Form CollectionLists all of the form elements and their values being POSTed. Server Variables Lists all the server variables and their values

Building Applications using ASP.NET and C# / Session 15 / 6 of 17 Trace Example void Page_Init() { Trace.Warn("This is a message from the Page Init Event"); } void Page_Load(Object Sender, EventArgs E) { Trace.Write("This is a message from the Page Load Event"); } Testing Trace...

Building Applications using ASP.NET and C# / Session 15 / 7 of 17 Trace Example - Output

Building Applications using ASP.NET and C# / Session 15 / 8 of 17 Checking Trace … if(Trace.IsEnabled) { Trace.Warn(“I’m inside Init now!”); } … To check if trace is enabled

Building Applications using ASP.NET and C# / Session 15 / 9 of 17 Application Level Tracing

Building Applications using ASP.NET and C# / Session 15 / 10 of 17 Trace Tag Parameters ParameterDescription requestLimitSets the number of trace requests to store on the server. Default 10 traceModeSets wether the statistics should be arranged according to time or category (takes in value sortByCategory or sortByTime). Default sortByTime pageOutputSet whether the trace information is to be displayed at the bottom of every page. Default False EnabledSets whether application level tracing is to be enabled or disabled. Default True localOnlySets whether Tracing is enabled for localhost users or for all users. Default True

Building Applications using ASP.NET and C# / Session 15 / 11 of 17 Debugging an Application - 1

Building Applications using ASP.NET and C# / Session 15 / 12 of 17 Debugging an Application - 2

Building Applications using ASP.NET and C# / Session 15 / 13 of 17 CachingCaching Caching - is a technique used to increase performance by keeping frequently accessed data in memory

Building Applications using ASP.NET and C# / Session 15 / 14 of 17 Output Caching void Page_Load(Object Src, EventArgs E) { TimeGen.Text = DateTime.Now.ToString("G"); } Using the Output Cache this page was generated on: Response.Cache.SetExpires(DateTime.Now.AddSeconds(60)); Response.Cache.SetSlidingExpiration(true); Setting duration of cache using the following methods

Building Applications using ASP.NET and C# / Session 15 / 15 of 17 Data Caching - 1 void Page_Load(Object Src, EventArgs E){ DataView Source; Source = (DataView)Cache["MyCache"]; if (Source == null) { SqlConnection myConnection = new SqlConnection ("server=(local)\\NetSDK;database=pubs;uid=sa; pwd="); SqlDataAdapter myCommand = new SqlDataAdapter("select * from employee", myConnection); A

Building Applications using ASP.NET and C# / Session 15 / 16 of 17 Data Caching - 2 DataSet ds = new DataSet(); myCommand.Fill(ds, "employee"); Source = new DataView(ds.Tables["employee"]); Cache["MyCache"] = Source; CacheMsg.Text = "Dataset created from Table"; } else { CacheMsg.Text = "Dataset retrieved from Cache"; } MyDataGrid.DataSource=Source; MyDataGrid.DataBind(); } Caching Data A

Building Applications using ASP.NET and C# / Session 15 / 17 of 17 Data Caching - 3