From 3c6845f77822f04374bc4c9b4f0de0b92b13cfbe Mon Sep 17 00:00:00 2001 From: Genevieve Warren Date: Mon, 13 Apr 2020 23:06:06 -0700 Subject: [PATCH 1/2] update add web reference instructions --- .../consuming-a-dataset-from-an-xml-web-service.md | 11 +++++++---- ...g-ws-i-basic-profile-1-1-interoperable-services.md | 6 +++--- .../config-wcf-service-with-aspnet-web-service.md | 7 ++++--- 3 files changed, 14 insertions(+), 10 deletions(-) diff --git a/docs/framework/data/adonet/dataset-datatable-dataview/consuming-a-dataset-from-an-xml-web-service.md b/docs/framework/data/adonet/dataset-datatable-dataview/consuming-a-dataset-from-an-xml-web-service.md index 2dfd9b9e2f68d..218a54f7bd370 100644 --- a/docs/framework/data/adonet/dataset-datatable-dataview/consuming-a-dataset-from-an-xml-web-service.md +++ b/docs/framework/data/adonet/dataset-datatable-dataview/consuming-a-dataset-from-an-xml-web-service.md @@ -6,7 +6,8 @@ dev_langs: - "vb" ms.assetid: 9edd6b71-0fa5-4649-ae1d-ac1c12541019 --- -# Consuming a DataSet from an XML Web Service +# Consume a DataSet from an XML web service + The was architected with a disconnected design, in part to facilitate the convenient transport of data over the Internet. The **DataSet** is "serializable" in that it can be specified as an input to or output from XML Web services without any additional coding required to stream the contents of the **DataSet** from an XML Web service to a client and back. The **DataSet** is implicitly converted to an XML stream using the DiffGram format, sent over the network, and then reconstructed from the XML stream as a **DataSet** on the receiving end. This gives you a very simple and flexible method for transmitting and returning relational data using XML Web services. For more information about the DiffGram format, see [DiffGrams](diffgrams.md). The following example shows how to create an XML Web service and client that use the **DataSet** to transport relational data (including modified data) and resolve any updates back to the original data source. @@ -14,7 +15,7 @@ The was architected with a disconnected design, in pa > [!NOTE] > We recommend that you always consider security implications when creating an XML Web service. For information on securing an XML Web service, see [Securing XML Web Services Created Using ASP.NET](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/w67h0dw7(v=vs.100)). -### To create an XML Web service that returns and consumes a DataSet +## Create an XML web service 1. Create the XML Web service. @@ -183,9 +184,11 @@ The was architected with a disconnected design, in pa 3. Create an XML Web service client. - If you want to have Visual Studio generate the Web service proxy class for you, simply create the client project, and, in the Solution Explorer window, right-click the project, click **Add Web Reference**, and select the Web service from the list of available Web services (this may require supplying the address of the Web service endpoint, if the Web service isn't available within the current solution, or on the current computer.) If you create the XML Web service proxy yourself (as described in the previous step), you can import it into your client code and consume the XML Web service methods. The following sample code imports the proxy library, calls **GetCustomers** to get a list of customers, adds a new customer, and then returns a **DataSet** with the updates to **UpdateCustomers**. + If you want to have Visual Studio generate the Web service proxy class for you, simply create the client project, and, in the Solution Explorer window, right-click the project, and then select **Add** > **Service Reference**. In the **Add Service Reference** dialog box, select **Advanced**, and then select **Add Web Reference**. Select the Web service from the list of available Web services (this may require supplying the address of the Web service endpoint if the Web service isn't available within the current solution or on the current computer). If you create the XML Web service proxy yourself (as described in the previous step), you can import it into your client code and consume the XML Web service methods. + + The following sample code imports the proxy library, calls **GetCustomers** to get a list of customers, adds a new customer, and then returns a **DataSet** with the updates to **UpdateCustomers**. - Notice that the example passes the **DataSet** returned by **DataSet.GetChanges** to **UpdateCustomers** because only modified rows need to be passed to **UpdateCustomers**. **UpdateCustomers** returns the resolved **DataSet**, which you can then **Merge** into the existing **DataSet** to incorporate the resolved changes and any row error information from the update. The following code assumes that you have used Visual Studio to create the Web reference, and that you have renamed the Web reference to DsSample in the **Add Web Reference** dialog box. + The example passes the **DataSet** returned by **DataSet.GetChanges** to **UpdateCustomers** because only modified rows need to be passed to **UpdateCustomers**. **UpdateCustomers** returns the resolved **DataSet**, which you can then **Merge** into the existing **DataSet** to incorporate the resolved changes and any row error information from the update. The following code assumes that you have used Visual Studio to create the Web reference, and that you have renamed the Web reference to DsSample in the **Add Web Reference** dialog box. ```vb Imports System diff --git a/docs/framework/wcf/creating-ws-i-basic-profile-1-1-interoperable-services.md b/docs/framework/wcf/creating-ws-i-basic-profile-1-1-interoperable-services.md index eaae29db2c2b2..215a9115989b7 100644 --- a/docs/framework/wcf/creating-ws-i-basic-profile-1-1-interoperable-services.md +++ b/docs/framework/wcf/creating-ws-i-basic-profile-1-1-interoperable-services.md @@ -15,15 +15,15 @@ To configure a WCF service endpoint to be interoperable with ASP.NET Web service - Do not use callback and session contract features or transaction behaviors on your service endpoint - You can optionally enable support for HTTPS and transport-level client authentication on the binding. +You can optionally enable support for HTTPS and transport-level client authentication on the binding. - The following features of the class require functionality beyond WS-I Basic Profile 1.1: +The following features of the class require functionality beyond WS-I Basic Profile 1.1: - Message Transmission Optimization Mechanism (MTOM) message encoding controlled by the property. Leave this property at its default value, which is to not use MTOM. - Message security controlled by the value provides WS-Security support compliant with WS-I Basic Security Profile 1.0. Leave this property at its default value, which is to not use WS-Security. - To make the metadata for a WCF service available to ASP.NET, use the Web service client generation tools: [Web Services Description Language Tool (Wsdl.exe)](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/7h3ystb6%28v=vs.100%29), [Web Services Discovery Tool (Disco.exe)](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/cy2a3ybs%28v=vs.100%29), and the `Add Web Reference` feature in Visual Studio; you must enable metadata publication. For more information, see [Publishing Metadata Endpoints](publishing-metadata-endpoints.md). +To make the metadata for a WCF service available to ASP.NET, use the Web service client generation tools: [Web Services Description Language Tool (Wsdl.exe)](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/7h3ystb6%28v=vs.100%29), [Web Services Discovery Tool (Disco.exe)](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/cy2a3ybs%28v=vs.100%29), and the **Add Web Reference** feature in Visual Studio. Enable metadata publication. For more information, see [Publishing Metadata Endpoints](publishing-metadata-endpoints.md). ## Example diff --git a/docs/framework/wcf/feature-details/config-wcf-service-with-aspnet-web-service.md b/docs/framework/wcf/feature-details/config-wcf-service-with-aspnet-web-service.md index 30bd9e0f74a8c..5c85462743753 100644 --- a/docs/framework/wcf/feature-details/config-wcf-service-with-aspnet-web-service.md +++ b/docs/framework/wcf/feature-details/config-wcf-service-with-aspnet-web-service.md @@ -7,13 +7,14 @@ dev_langs: ms.assetid: 48e1cd90-de80-4d6c-846e-631878955762 --- # How to: Configure WCF Service to Interoperate with ASP.NET Web Service Clients + To configure a Windows Communication Foundation (WCF) service endpoint to be interoperable with ASP.NET Web service clients, use the type as the binding type for your service endpoint. You can optionally enable support for HTTPS and transport-level client authentication on the binding. ASP.NET Web service clients do not support MTOM message encoding, so the property should be left as its default value, which is . ASP.Net Web Service clients do not support WS-Security, so the should be set to . - To make the metadata for a WCF service available to ASP.NET Web service proxy generation tools (that is, [Web Services Description Language Tool (Wsdl.exe)](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/7h3ystb6(v%3dvs.100)), [Web Services Discovery Tool (Disco.exe)](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/cy2a3ybs(v=vs.100)), and the Add Web Reference feature in Visual Studio), you should expose an HTTP/GET metadata endpoint. + To make the metadata for a WCF service available to ASP.NET Web service proxy generation tools (that is, [Web Services Description Language Tool (Wsdl.exe)](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/7h3ystb6(v%3dvs.100)), [Web Services Discovery Tool (Disco.exe)](https://docs.microsoft.com/previous-versions/dotnet/netframework-4.0/cy2a3ybs(v=vs.100)), and the **Add Web Reference** feature in Visual Studio), you should expose an HTTP/GET metadata endpoint. -### To add a WCF endpoint that is compatible with ASP.NET Web service clients in code +## Add an endpoint in code 1. Create a new instance @@ -23,7 +24,7 @@ To configure a Windows Communication Foundation (WCF) service endpoint to be int 4. Enable an HTTP/GET metadata endpoint for your service. For details see [How to: Publish Metadata for a Service Using Code](../../../../docs/framework/wcf/feature-details/how-to-publish-metadata-for-a-service-using-code.md). -### To add a WCF endpoint that is compatible with ASP.NET Web service clients in a configuration file +## Add an endpoint in a configuration file 1. Create a new binding configuration. For details, see the [How to: Specify a Service Binding in Configuration](../../../../docs/framework/wcf/how-to-specify-a-service-binding-in-configuration.md). From d7872df0dececaa131a5917491369e731f727a0e Mon Sep 17 00:00:00 2001 From: Genevieve Warren Date: Tue, 14 Apr 2020 08:57:02 -0700 Subject: [PATCH 2/2] fix trailing spaces lint --- .../consuming-a-dataset-from-an-xml-web-service.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/framework/data/adonet/dataset-datatable-dataview/consuming-a-dataset-from-an-xml-web-service.md b/docs/framework/data/adonet/dataset-datatable-dataview/consuming-a-dataset-from-an-xml-web-service.md index 218a54f7bd370..6dee77395816a 100644 --- a/docs/framework/data/adonet/dataset-datatable-dataview/consuming-a-dataset-from-an-xml-web-service.md +++ b/docs/framework/data/adonet/dataset-datatable-dataview/consuming-a-dataset-from-an-xml-web-service.md @@ -185,7 +185,7 @@ The was architected with a disconnected design, in pa 3. Create an XML Web service client. If you want to have Visual Studio generate the Web service proxy class for you, simply create the client project, and, in the Solution Explorer window, right-click the project, and then select **Add** > **Service Reference**. In the **Add Service Reference** dialog box, select **Advanced**, and then select **Add Web Reference**. Select the Web service from the list of available Web services (this may require supplying the address of the Web service endpoint if the Web service isn't available within the current solution or on the current computer). If you create the XML Web service proxy yourself (as described in the previous step), you can import it into your client code and consume the XML Web service methods. - + The following sample code imports the proxy library, calls **GetCustomers** to get a list of customers, adds a new customer, and then returns a **DataSet** with the updates to **UpdateCustomers**. The example passes the **DataSet** returned by **DataSet.GetChanges** to **UpdateCustomers** because only modified rows need to be passed to **UpdateCustomers**. **UpdateCustomers** returns the resolved **DataSet**, which you can then **Merge** into the existing **DataSet** to incorporate the resolved changes and any row error information from the update. The following code assumes that you have used Visual Studio to create the Web reference, and that you have renamed the Web reference to DsSample in the **Add Web Reference** dialog box.