System.Xml.XmlException: 'Element' is aninvalid node type. Line 8, position 5.\r\n atSystem.Xml.XmlReader.ReadElementString()\r\n atMicrosoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReader1.Read117_Response()\r\n --- End of inner exception stacktrace ---\r\n atSystem.Xml.Serialization.XmlSerializer.Deserialize(XmlReaderxmlReader, String encodingStyle, XmlDeserializationEventsevents)\r\n atSystem.Xml.Serialization.XmlSerializer.Deserialize(XmlReaderxmlReader, XmlDeserializationEvents events)\r\n atSystem.Xml.Serialization.XmlSerializer.Deserialize(XmlReaderxmlReader)\r\n atSystem.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, StreamresponseStream, Boolean asyncCall)\r\n atSystem.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters) System.InvalidOperationException: There is an error in XMLdocument (8, 5) ---> System.Xml.XmlException: 'Element' is aninvalid node type. Line 8, position 5.\r\n atSystem.Xml.XmlReader.ReadElementString()\r\n atMicrosoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReader1.Read117_Response() Please help, Regards, Jasmeet -------------------------------- From: Jasmeet Sangari ----------------------- Posted by a user from .NET 247 ([url]http://www.dotnet247.com/[/url]) ENFfwlgO70CwB6Eqi6RnQg== [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => [htmlstate] => on_nl2br [postusername] => Jasmeet Sangari via .NET 247 [ip] => anonymous@dotne [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 1 [islastshown] => [isfirstshown] => 1 [attachments] => [allattachments] => ) --> System.Xml.XmlException: 'Element' is an invalid node type. Line 8, position 5.\r\n at System.Xml.XmlReader.ReadElementString()\r\n at Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReader1.Read117_Response()\r\n --- End of inner exception stack trace ---\r\n at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader, String encodingStyle, XmlDeserializationEvents events)\r\n at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader, XmlDeserializationEvents events)\r\n at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader)\r\n at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)\r\n at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters) System.InvalidOperationException: There is an error in XML document (8, 5) ---> System.Xml.XmlException: 'Element' is an invalid node type. Line 8, position 5.\r\n at System.Xml.XmlReader.ReadElementString()\r\n at Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReader1.Read117_Response() Please help, Regards, Jasmeet -------------------------------- From: Jasmeet Sangari ----------------------- Posted by a user from .NET 247 ([url]http://www.dotnet247.com/[/url]) ENFfwlgO70CwB6Eqi6RnQg== [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => [ref] => [htmlstate] => on_nl2br [postusername] => Dino Chiesa [Microsoft] [ip] => dinoch@online.m [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 2 [islastshown] => 1 [isfirstshown] => [attachments] => [allattachments] => ) --> .NET Client / Java Web Service Problem - ASP.NET Web Services

.NET Client / Java Web Service Problem - ASP.NET Web Services

Hi, I am writting a .NET Client for a Java Web Service.I have createda .cs file from the WSDL and the XSD's Given. I am trying to query a Web Service which has the description::: // Service Description::::::: [System.Web.Services.Protocols.SoapDoentMethodAt tribute("urn:#solicitar",Use=System.Web.Services.D escription.SoapBindingUse.Literal,ParameterStyle=S ystem.Web.Services.Protocols.SoapParameterStyle.Ba re)] [return: System.Xml.Serialization.XmlElementAttribute("Resp onse",Namespace="http://example")] public stringsolicitar([System.Xml.Serialization.XmlElementAttribute(Names pace="http://example")] idMesage Mesage) { object[] results = this.Invoke("Function", new object[]{Mesage}); return ((string)(results[0])); But when I query the Web Service from my Client I get an ErrorLike::: Error in the Client::::: "System.InvalidOperationException: There is an error in XMLdoent (8, 5). ---> System.Xml.XmlException: 'Element' is aninvalid node type. Line 8, position 5.\r\n atSystem.Xml.XmlReader.ReadElementString()\r\n atMicrosoft.Xml.Serialization.GeneratedAssembly.Xm ...

  1. #1

    Default .NET Client / Java Web Service Problem

    Hi,
    I am writting a .NET Client for a Java Web Service.I have createda .cs file from the WSDL and the XSD's Given.
    I am trying to query a Web Service which has the description:::

    // Service Description:::::::

    [System.Web.Services.Protocols.SoapDoentMethodAt tribute("urn:#solicitar",Use=System.Web.Services.D escription.SoapBindingUse.Literal,ParameterStyle=S ystem.Web.Services.Protocols.SoapParameterStyle.Ba re)]

    [return: System.Xml.Serialization.XmlElementAttribute("Resp onse",Namespace="http://example")]
    public stringsolicitar([System.Xml.Serialization.XmlElementAttribute(Names pace="http://example")] idMesage Mesage) {
    object[] results = this.Invoke("Function", new object[]{Mesage});
    return ((string)(results[0]));


    But when I query the Web Service from my Client I get an ErrorLike:::


    Error in the Client:::::

    "System.InvalidOperationException: There is an error in XMLdoent (8, 5). ---> System.Xml.XmlException: 'Element' is aninvalid node type. Line 8, position 5.\r\n atSystem.Xml.XmlReader.ReadElementString()\r\n atMicrosoft.Xml.Serialization.GeneratedAssembly.Xm lSerializationReader1.Read117_Response()\r\n --- End of inner exception stacktrace ---\r\n atSystem.Xml.Serialization.XmlSerializer.Deseriali ze(XmlReaderxmlReader, String encodingStyle, XmlDeserializationEventsevents)\r\n atSystem.Xml.Serialization.XmlSerializer.Deseriali ze(XmlReaderxmlReader, XmlDeserializationEvents events)\r\n atSystem.Xml.Serialization.XmlSerializer.Deseriali ze(XmlReaderxmlReader)\r\n atSystem.Web.Services.Protocols.SoapHttpClientProt ocol.ReadResponse(SoapClientMessage message, WebResponse response, StreamresponseStream, Boolean asyncCall)\r\n atSystem.Web.Services.Protocols.SoapHttpClientProt ocol.Invoke(String methodName, Object[] parameters)

    System.InvalidOperationException: There is an error in XMLdoent (8, 5) ---> System.Xml.XmlException: 'Element' is aninvalid node type. Line 8, position 5.\r\n atSystem.Xml.XmlReader.ReadElementString()\r\n atMicrosoft.Xml.Serialization.GeneratedAssembly.Xm lSerializationReader1.Read117_Response()


    Please help,

    Regards,

    Jasmeet


    --------------------------------
    From: Jasmeet Sangari

    -----------------------
    Posted by a user from .NET 247 ([url]http://www.dotnet247.com/[/url])

    <Id>ENFfwlgO70CwB6Eqi6RnQg==</Id>
    Jasmeet Sangari via .NET 247 Guest

  2. #2

    Default Re: .NET Client / Java Web Service Problem

    you need to examine the XML (response) that is being returned by the
    service.
    Try something like proxytrace, or the TCPMonitor tool in the Apache AXIS
    toolkit.
    etc

    -D


    "Jasmeet Sangari via .NET 247" <anonymousdotnet247.com> wrote in message
    news:enymhtAKFHA.1176TK2MSFTNGP15.phx.gbl...
    Hi,
    I am writting a .NET Client for a Java Web Service.I have created a .cs file
    from the WSDL and the XSD's Given.
    I am trying to query a Web Service which has the description:::

    // Service Description:::::::

    [System.Web.Services.Protocols.SoapDoentMethodAt tribute("urn:#solicitar",
    Use=System.Web.Services.Description.SoapBindingUse .Literal,
    ParameterStyle=System.Web.Services.Protocols.SoapP arameterStyle.Bare)]

    [return: System.Xml.Serialization.XmlElementAttribute("Resp onse",
    Namespace="http://example")]
    public string
    solicitar([System.Xml.Serialization.XmlElementAttribute(Names pace="http://example")]
    idMesage Mesage) {
    object[] results = this.Invoke("Function", new object[] {Mesage});
    return ((string)(results[0]));


    But when I query the Web Service from my Client I get an Error Like:::


    Error in the Client:::::

    "System.InvalidOperationException: There is an error in XML doent (8,
    5). ---> System.Xml.XmlException: 'Element' is an invalid node type. Line 8,
    position 5.\r\n at System.Xml.XmlReader.ReadElementString()\r\n at
    Microsoft.Xml.Serialization.GeneratedAssembly.XmlS erializationReader1.Read117_Response()\r\n
    --- End of inner exception stack trace ---\r\n at
    System.Xml.Serialization.XmlSerializer.Deserialize (XmlReader xmlReader,
    String encodingStyle, XmlDeserializationEvents events)\r\n at
    System.Xml.Serialization.XmlSerializer.Deserialize (XmlReader xmlReader,
    XmlDeserializationEvents events)\r\n at
    System.Xml.Serialization.XmlSerializer.Deserialize (XmlReader xmlReader)\r\n
    at
    System.Web.Services.Protocols.SoapHttpClientProtoc ol.ReadResponse(SoapClientMessage
    message, WebResponse response, Stream responseStream, Boolean asyncCall)\r\n
    at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
    methodName, Object[] parameters)

    System.InvalidOperationException: There is an error in XML doent (8,
    5) ---> System.Xml.XmlException: 'Element' is an invalid node type. Line 8,
    position 5.\r\n at System.Xml.XmlReader.ReadElementString()\r\n at
    Microsoft.Xml.Serialization.GeneratedAssembly.XmlS erializationReader1.Read117_Response()


    Please help,

    Regards,

    Jasmeet


    --------------------------------
    From: Jasmeet Sangari

    -----------------------
    Posted by a user from .NET 247 ([url]http://www.dotnet247.com/[/url])

    <Id>ENFfwlgO70CwB6Eqi6RnQg==</Id>


    Dino Chiesa [Microsoft] Guest

Similar Threads

  1. Stateful Connection - C# Client talking to Java Web Service
    By kapil singhal via DotNetMonster.com in forum ASP.NET Web Services
    Replies: 1
    Last Post: March 21st, 05:29 PM
  2. Problems accessing dot net web service from java client
    By David Laub in forum ASP.NET Web Services
    Replies: 0
    Last Post: January 7th, 03:21 PM
  3. Reading .Net Web service user defined struct from a Java client
    By Ghislain Tanguay in forum ASP.NET Web Services
    Replies: 0
    Last Post: August 5th, 01:18 PM
  4. Replies: 1
    Last Post: June 1st, 07:36 PM
  5. Problem calling a .net web service from an existing java client.
    By Chris Bardon in forum ASP.NET Web Services
    Replies: 0
    Last Post: April 28th, 02:09 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •