How to update OData WCF in Visual Studio 2017?

Viewed 4608

Trying to update Service Reference in an existing project, I got an error that says,

The specified OData API cannot be updated because OData APIs are now only supported with Connected Services.

enter image description here

The aka link (http://aka.ms/odatavsclientguidance) leads to http://odata.github.io/odata.net/#OData-Client-Code-Generation-Tool.

enter image description here

There is no instruction for VS 2017.

The instruction below leads me to the OData Connected Serve VS extension. (https://marketplace.visualstudio.com/items?itemName=laylaliu.ODataConnectedService) enter image description here

And it appears that extension cannot be installed in VS 2017. enter image description here

Scroll to the bottom of the extension description page, we will see all the questions about its VS 2017 version.

enter image description here

So the question: is that OData extension the only to update OData Service in VS 2017? What walk around do we have?

2 Answers

The official Visual Studio Marketplace code generation tool, which you refer to in your post, now supports Visual Studio 2017.

One notable difference from how one would normally go about setting up OData references is that where one would previously use Visual Studio's "Add Service Reference" directly to generate the relevant code, installing the tool adds a "Add Connected Service" instead.

See also the discussion in this GitHub issue.

Related