TAILIEUCHUNG - Pro Entity Framework 4 0 Depositfiles_9

Tham khảo tài liệu 'pro entity framework 4 0 depositfiles_9', công nghệ thông tin, kỹ thuật lập trình phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả | CHAPTER 13 DATABINDING WITH THE ENTITY FRAMEWORK WPF Data Binding This section discusses binding with Windows Presentation Foundation WPF . In this example you focus on the sales side of things pulling in SalesOrderHeader and SalesOrderDetail information to populate a simple WPF form. If you ve never developed an application with WPF before don t fear. This example doesn t go deep into the intricacies of WPF there are many great WPF books out there but you get an idea of how to build a simple EF data binding application for WPF. Creating a Project Binding in WPF is quite different from a Windows form because WPF has no built-in binding controls. The first thing you need to do is create the project in the existing solution that you ve been using choose File Add New Project. This opens the Add New Project dialog show earlier in Figure 13-1. This time however you want to select the WPF Application template. Give it the name WPFBinding and click OK. Just like your WinFormsBinding project add a reference to the EF40Data project to this WPFBinding project. Before you start adding code drag a WPF list box onto the window. Again you aren t going for a well-designed layout you simply need a list box. In the code I ve renamed Window1 to MainWindow. You may want to do the same to avoid any confusion. Adding Some Code Let s add some code. Modify the code behind the MainWindow to look like the following. Notice the addition of some using statements besides the default using statements some variable declarations at the Window level and some code in the Loaded event for the window using EF40Data using System using using using using using using using using using using using using using using .

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.