TAILIEUCHUNG - Professional ASP.NET 3.5 in C# and Visual Basic Part 100

Professional in C# and Visual Basic Part 100. Building on the revolutionary release, 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 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 20 AJAX Control Toolkit html xmlns http 1999 xhtml head runat server title ConfirmButtonExtender title head body form id form1 runat server div asp ScriptManager ID ScriptManager1 runat server asp ScriptManager cc1 ConfirmButtonExtender ID ConfirmButtonExtender1 runat server TargetControlID Button1 ConfirmText Are you sure you wanted to click this button cc1 ConfirmButtonExtender asp Button ID Button1 runat server Text Button div form body html In this case the ConfirmButtonExtender extends the Button1 server control and adds a confirmation dialog using the text defined with the CofirmText property. This page is shown in Figure 20-15. Figure 20-15 If the end user clicks OK in this instance then the page will function normally as if the dialog never occurred. However if Cancel is clicked by default the dialog will disappear and the form will not be submitted it will be as if the button was not clicked at all . In this case you can also capture the Cancel button being clicked and perform a client-side operation by using the OnClientClick event and giving it a value of a client-side JavaScript function. Instead of using the browsers modal dialogs you can even go as far as creating your own to use as the confirmation form. To accomplish this task you will need to use the new ModalPopupExtender server control. The ModalPopupExtender control points to another control to use for the confirmation. Listing 20-9 shows how to make use of this control. Listing 20-9 Using the ModalPopupExtender control to create your own confirmation form @ Page Language C @ Register Assembly AjaxControlToolkit Namespace AjaxControlToolkit TagPrefix cc1 948 Chapter 20 AJAX Control Toolkit html xmlns http 1999 xhtml head runat server title ConfirmButtonExtender title head body form id form1 runat server div asp ScriptManager ID ScriptManager1 runat server asp ScriptManager cc1 ConfirmButtonExtender ID ConfirmButtonExtender1 runat server .

TỪ KHÓA 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.