Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / January 2006

Tip: Looking for answers? Try searching our database.

Namespace prefix

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
marc - 22 Dec 2005 16:34 GMT
Hi,

I would like to add a prefix to a WebService namespace

When I write :

[WebService(Namespace = "http://MyNamespace/WebService")]
...

I have the following response when I test my WebService.

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>

////////////
    <TestXMLResponse xmlns="http://MyNamespace/WebService">
/////////////

      <TestXMLResult>xml</TestXMLResult>
    </TestXMLResponse>
  </soap:Body>
</soap:Envelope>

I would like instead : (I only put the modified line)

////////////
    <TestXMLResponse xmlns:mns="http://MyNamespace/WebService">
////////////

How can I do that ?

TIA,

Marc
amar.ingole@solversa.com - 30 Dec 2005 10:46 GMT
Hi,

I am also facing fame problem of adding prefix to the namespace.

If you got the solution can u please let me know the how it can be done.

Thanks,
Amar
marc - 02 Jan 2006 14:00 GMT
amar.ingole@solversa.com a écrit :
> Hi,
>
[quoted text clipped - 8 lines]
> Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
> Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...

Amar,

In fact my problem is that I cannot read the XML document that comes
from my webservice with namespace like that :
xmlns="http://MyNamespace".(xmlns:foo="http://MyNamespace" would be better)
I think it's a Saxon issue.(I call this WS from a Java application).

So by now I wrote a no conform WS with : [WebServiceBinding(ConformsTo =
WsiProfiles.None)]. So I can write parameter :ResponseNamespace = "" in
SoapDocumentMethod. The resulting XML document belong to no namespace,
and Saxon can read it.

I know that it's a bad workaround but I don't find other way to make it
work.

Marc

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.