The following steps helps you to perform the CRUD operations like adding, editing and deleting appointments on the Schedule control by using the web services in an ASP.NET application.
Step 2: Now, Create a database table with the necessary fields, as follows.
SQL Table Script
Note: You can create the table through Visual Studio as a local database or by using SQL Server Management Studio.
Step 3: Add the connection String configuration in the Web.Config page. Refer to the following code example.
Note: Change the ConnectionString value based on the database connection. Here, the “local database” connection string is mentioned.
Step 4: Create a web service with the CRUD operation functionality using the following steps:
Figure 1: Creation of the webservice
Figure 2: WebService1.asmx.cs file
Step 5: Build the sample and add the WebReference to your application using the following steps,
Figure 3: Select the Add ServiceReference option
Figure 4: WebService details
Figure 5: Service Reference Settings window
Figure 6: Add Web Reference
Figure 7: WebServices details
Figure 8: Details of the created WebServices
Figure 9: Reference added
Step 8: Run the sample and now you can perform CRUD operations on the schedule appointments which gets reflected appropriately in the Web Services too.
This page will automatically be redirected to the sign-in page in 10 seconds.