Đ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 7

Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ

Professional ASP.NET 3.5 in C# and Visual Basic Part 7. 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 1 Application and Page Frameworks Listing 1-5 A code-behind page VB Partial Class _Default Inherits System.Web.UI.Page Protected Sub Button1_Click ByVal sender As Object _ ByVal e As System.EventArgs Handles Buttonl.Click Labell.Text Hello TextBoxl.Text End Sub End Class C using System using System.Data using System.Configuration using System.Linq using System.Web using System.Web.Security using System.Web.UI using System.Web.UI.WebControls using System.Web.UI.WebControls.WebParts using System.Web.UI.HtmlControls using System.Xml.Linq public partial class _Default System.Web.UI.Page protected void Button1_Click object sender EventArgs e Labell.Text Hello Textboxl.Text The .aspx page using this ASP.NET 3.5 code-behind model has some attributes in the Page directive that you should pay attention to when working in this mode. The first is the CodeFile attribute. This is an attribute in the Page directive and is meant to point to the code-behind page that is used with this presentation page. In this case the value assigned is Default.aspx.vb or Default.aspx.cs. The second attribute needed is the Inherits attribute. This attribute was available in previous versions of ASP.NET but was little used before ASP.NET 2.0. This attribute specifies the name of the class that is bound to the page when the page is compiled. The directives are simple enough in ASP.NET 3.5. Look at the code-behind page from Listing 1-5. The code-behind page is rather simple in appearance because of the partial class capabilities that .NET 3.5 provides. You can see that the class created in the code-behind file uses partial classes employing the Partial keyword in Visual Basic 2008 and the partial keyword from C 2008. This enables you to simply place the methods that you need in your page class. In this case you have a button-click event and nothing else. Later in this chapter we look at the compilation process for both of these models. 12 Chapter 1 Application and Page Frameworks ASP.NET 3.5

TÀI LIỆU LIÊN QUAN
TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã 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.