Đang chuẩn bị liên kết để tải về tài liệu:
Professional ASP.NET 3.5 in C# and Visual Basic Part 151

Không đóng trình duyệt đến khi xuất hiện nút TẢI XUỐNG

Professional ASP.NET 3.5 in C# and Visual Basic Part 151. Building on the revolutionary ASP.NET 2.0 release, ASP.NET 3.5 adds several key new developer features including AJAX, LINQ, and a new CSS designer in Visual Web Developer 2008. The dramatic reduction in code that developers realized from the more than 50 new server controls in ASP.NET 2.0 now allows developers the time to make their applications more interactive with AJAX, to work with data in their preferred language with LINQ, and to build visually attractive and consistent standards-based sites with CSS | Chapter 32 Instrumentation Event Log Description Application Enables you to record application-specific events including whether a certain event was fired a page was loaded or a customer made a specific purchase Security Enables you to track security-related issues such as security changes and breaches System Enables you to track system-specific items such as issues that arise with components or drivers From your code you can write to any of the event logs defined in the preceding table as well as to any custom event logs that you might create. To accomplish this task create an example ASP.NET page that contains a multiline TextBox control and a Button control. On the Button1_ciick event you register the text you want placed in the text box directly into the Application event log. Your ASP.NET page should be similar to what is presented in Listing 32-2. Listing 32-2 Writing to the Application event log VB @ Page Language VB @ Import Namespace System.Diagnostics script runat server Protected Sub Page_Load ByVal sender As Object _ ByVai e As System.EventArgs If Not EventLog.SourceExists My Application Then EventLog.CreateEventSource My Application Application End If End Sub Protected Sub Button1_Click ByVal sender As Object _ ByVal e As System.EventArgs Dim el As EventLog New EventLog el.Source My Application el.WriteEntry TextBoxl.Text Labell.Text ENTERED TextBoxl.Text End Sub script html xmlns http www.w3.org 1999 xhtml head runat server title Working with Event Logs title head body form id form1 runat server div asp TextBox ID TextBox1 runat server Height 75px Continued 1465 Chapter 32 Instrumentation TextMode MultiLine Width 250px asp TextBox br br asp Button ID Button1 runat server OnClick Button1_Click Text Submit to custom event log br br asp Label ID Label1 runat server asp Label nbsp div form body html C @ Page Language C @ Import Namespace System.Diagnostics script runat server protected void Page_Load object sender EventArgs e if EventLog.SourceExists My .

TÀI LIỆU LIÊN QUAN
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.