TAILIEUCHUNG - Creating a Web Service

Tạo ra một dịch vụ Web Trong phần này, bạn sẽ tạo ra một dịch vụ Web có chứa một phương thức trả về một DataSet có chứa các hàng từ bảng Khách hàng. Bắt đầu VS NET và. Chọn File ➣ New ➣ dự án. Trong hộp thoại New Project, chọn Visual C # Dự án trong khung dự án Các loại trái, và chọn Web Service trong cửa sổ Templates ở bên phải. Nhập http://localhost/NorthwindWebService trong lĩnh vực Địa điểm (xem hình 17,1). Click OK để tiếp tục. . | Creating a Web Service In this section you ll create a Web service that contains a method that returns a DataSet containing rows from the Customers table. Start VS .NET and select File New Project. In the New Project dialog box select Visual C Projects in the Project Types pane on the left and select Web Service in the Templates pane on the right. Enter http localhost NorthwindWebService in the Location field see Figure . Click OK to continue. Figure Creating a Web service in VS .NET Note If you have installed IIS on a computer other than your local machine then replace localhost with the name of your remote computer in the Location field. After VS .NET has created the new project open Solution Explorer and delete the file from your project you ll be adding your own .asmx file next and it s easier to simply delete the initial file. Select Project Add Web Service and enter in the Name field of the Add New Item dialog box see Figure . Click Open to continue. VS .NET adds a file named to your project. Figure Adding a new Web service Select View Code to view the C code in the file. Listing shows my example file. using System using using using using using using namespace NorthwindWebService summary Summary description for Customers. summary WebService Namespace http DbProgramming NorthwindWebService public class Customers public Customers CODEGEN This call is required by the Web Services Designer InitializeComponent region Component Designer generated code Required by the Web Services Designer private IContainer components null Ill summary Required method for Designer support - do not modify Ill the contents of this method with the

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.