.Net Standard project, How to use System.ServiceModel classes
Asked Answered
E

1

9

I have converted PCL project into .Net Standard 1.5 project. I have installed System.ServiceModel package from nuget. but cannot find way to use System.ServiceModel namespace.

Any help is appreciated.

Elka answered 29/12, 2016 at 17:30 Comment(4)
Why you have to use and where? because System.ServiceModel namespace is not compatible in .net 1.5 i am not sure but i hopeSub
@Sub I was calling WCF with custom behaviourElka
That's why serviceModel namespace is supported in .net 3.5 and onwardSub
@Rajput, Issue resolved, when i installed System.ServiceModel.Security package. I got the System.ServiceModel namespace. It is a bug in VS.Elka
E
27

Installing System.ServiceModel.Security package has resolved the issue.

After intalling above package. Now i can use System.ServiceModel namespace.

Also, i have to install System.ServiceModel.Http for proxies.

Elka answered 2/1, 2017 at 4:38 Comment(2)
I am trying to use WSHttpBinding. I install the two packages above as well as System.ServiceModel.Web and it still does not recognize the object. Is this binding just not supported in .net standard?Dissenter
@JonesCola, WSHttpBinding is supported in .Net Standard. This is something, i have achieved after a lot of hard work for both Json based csproj based .Net Standard project. Unfortunately, i don't remember the steps, It's been a long time. You should give it more tries. and also keep an eye open, someone can help here in community.Elka

© 2022 - 2024 — McMap. All rights reserved.