locked
Core 2.1, RestApi and WebService RRS feed

  • Question

  • User1525382536 posted
    1. when i do a test request on my pc (win10), the json key's must match the field in my request class (whether is start with small or capital letter).this isn't a problem when i upload it to a server : win2016 - any idea what can be different? some setting in the server level?
    2. i had problem when deploying the same project to prod, when called a method which call's a web servicei got an error :
    3. Could not load file or assembly 'System.Private.ServiceModel, Version=4.1.2.4, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. The system cannot find the file specified.
      i solved it changing tfrom
      <PackageReference Include="System.ServiceModel.Http" Version="4.4.*" />
      
      to
      
      <PackageReference Include="System.ServiceModel.Http" Version="4.5.*" />
      everything works ok and, but in VS i see the next error :
      Error Endpoint
      should i change version of any other dll? 
    Sunday, June 28, 2020 1:33 PM

All replies

  • User1120430333 posted

    should i change version of any other dll?

    if the program works then leave it alone.

    Sunday, June 28, 2020 6:06 PM
  • User711641945 posted

    Hi wanttolearn1,

    Could you please give the sample with code instead of screenshot?And what it your `MemberShipManageSoapClient`?What is your detailed error message?

    Best Regards,

    Rena

    Monday, June 29, 2020 7:40 AM
  • User1525382536 posted

    Hi, I am referencing a WS written in C#, and setting up an endpoint via code.

    this is the code :

     client = new MemberShipManageSoapClient(MemberShipWS                        .MemberShipManageSoapClient.EndpointConfiguration.MemberShipManageSoap12);
                        client.Endpoint.Address = new EndpointAddress(memberShipWsEndPoint);
                        getUserResponse = await client.GetUserAsync(directaccount);

    Monday, June 29, 2020 4:40 PM
  • User475983607 posted

    You need the following library; https://www.nuget.org/packages/System.ServiceModel.Primitives/

    System.ServiceModel.Primitives

    Monday, June 29, 2020 7:10 PM
  • User1525382536 posted

    Hi,

    System.ServiceModel.Primitives

    is part  of : System.ServiceModel.Security which is already part of the project.

    any way this issue got solved (not clear how).

    Monday, June 29, 2020 9:13 PM
  • User-474980206 posted

    why are you on 2.0? its not supported. you should be using 2.1

    Monday, June 29, 2020 9:52 PM
  • User1525382536 posted

    sorry it's 201 fixed title

    Tuesday, June 30, 2020 8:24 AM