Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9260537
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T12:55:06+00:00 2026-06-18T12:55:06+00:00

I have a .NET client calling into a SOAP .asmx web service. The client

  • 0

I have a .NET client calling into a SOAP .asmx web service. The client I’m developing is itself a WCF service under .NET 4. The destination .asmx web service is a Service Reference in the application. I don’t have any control over the destination.

The problem is that when calling a web service, the XML that is created for the call doesn’t include a particular namespace in the root element of the serialized XML of the proxy classes being sent.

Rather, it applies the namespace for a handful of elements nested within the document.

When using the proxy classes:

 var x = new RemoteService_PortTypeClient();
 x.SomeMethod(somePayload);

The destination service returns an exception when formatted with the hl7 namespace throughout:

Could not find schema information for the element ‘urn:hl7-org:v3:typeId’.

The current serialized proxy object (somePayload) is being sent as:

<MyRoot xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
        xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    ....
    <MyNode value="20120801100803" xmlns="urn:hl7-org:v3" /> 

How I’d like it to be sent:

<MyRoot xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
        xmlns:xsd="http://www.w3.org/2001/XMLSchema"
        xmlns="urn:hl7-org:v3">
    ....
    <MyNode value="20120801100803"  /> 

How can I force my client to declare the namespace in the root, rather than being scattered in the element?

I know that having this namespace in the root will be accepted without error by the service, as it’s been demonstrated to work in that way.

Are there declarations/attributes in References.cs or web.config or other to force this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T12:55:08+00:00Added an answer on June 18, 2026 at 12:55 pm

    I solved my own issue by creating a Web Reference instead of a Service Reference.

    enter image description here

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

SCENARIO I have to access a web service with a .NET client. The service
I have a .NET Web Service running in VS2005 and a client that consumes
I have a REST service consumed by a .Net WCF client. When an error
I have written a .NET Windows service which has a WCF service built into
I have an ASP.NET MVC web app whose controllers use WCF to call into
I'm writing UI to test an asmx web service. Server and client are .NET.
I have a .NET WCF web service running on a server that I access
I have a WCF client that is calling an arbitrary SOAP endpoint in which
I have an asmx web service that is part of my ASP.Net web application.
I'm testing calling a SOAP based service from a .net client app and am

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.