Professional Web Applications Themes

Web Service Error - HTML & CSS

Example 'hello word' produce error (see below). Help me please!!! Thanks in advance, Primoz error description Object reference not set to an instance of an object. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.NullReferenceException: Object reference not set to an instance of an object. Source Error: Line 1201: Line 1202: OperationBinding FindHttpBinding(string verb) { Line 1203: foreach (ServiceDescription description in serviceDescriptions) { Line 1204: foreach (Binding binding in description.Bindings) { Line 1205: HttpBinding httpBinding ...

  1. #1

    Default Web Service error

    Example 'hello word' produce error (see below). Help me please!!!

    Thanks in advance,

    Primoz

    error description
    Object reference not set to an instance of an object.
    Description: An unhandled exception occurred during the execution of the
    current web request. Please review the stack trace for more information
    about the error and where it originated in the code.

    Exception Details: System.NullReferenceException: Object reference not set
    to an instance of an object.

    Source Error:

    Line 1201:
    Line 1202: OperationBinding FindHttpBinding(string verb) {
    Line 1203: foreach (ServiceDescription description in
    serviceDescriptions) {
    Line 1204: foreach (Binding binding in description.Bindings) {
    Line 1205: HttpBinding httpBinding =
    (HttpBinding)binding.Extensions.Find(typeof(HttpBi nding));

    Source File:
    d:\winnt\microsoft.net\framework\v1.1.4322\Config\ DefaultWsdlHelpGenerator.a
    spx Line: 1203

    Stack Trace:

    [NullReferenceException: Object reference not set to an instance of an
    object.]
    ASP.DefaultWsdlHelpGenerator_aspx.FindHttpBinding( String verb) in
    d:\winnt\microsoft.net\framework\v1.1.4322\Config\ DefaultWsdlHelpGenerator.a
    spx:1203
    ASP.DefaultWsdlHelpGenerator_aspx.get_HttpPostOper ationBinding() in
    d:\winnt\microsoft.net\framework\v1.1.4322\Config\ DefaultWsdlHelpGenerator.a
    spx:441
    ASP.DefaultWsdlHelpGenerator_aspx.get_ShowingHttpP ost() in
    d:\winnt\microsoft.net\framework\v1.1.4322\Config\ DefaultWsdlHelpGenerator.a
    spx:456
    ASP.DefaultWsdlHelpGenerator_aspx.__Render__contro l13(HtmlTextWriter
    __output, Control parameterContainer) in
    d:\winnt\microsoft.net\framework\v1.1.4322\Config\ DefaultWsdlHelpGenerator.a
    spx:1435
    System.Web.UI.Control.RenderChildren(HtmlTextWrite r writer) +27
    System.Web.UI.HtmlControls.HtmlContainerControl.Re nder(HtmlTextWriter
    writer) +29
    System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
    System.Web.UI.Control.RenderChildren(HtmlTextWrite r writer) +72
    System.Web.UI.Control.Render(HtmlTextWriter writer) +7
    System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +243
    System.Web.UI.Page.ProcessRequestMain() +1929




    Pril Guest

  2. #2

    Default Web Service error

    Hi,

    Please check the attributes of the Web Method.
    If you want to make use of the session objects using Web
    services, you need to activate one of the attributes of
    the Web Method EnableSession = true.
    It's default value is false.

    [Web Method (true)]

    Hope this solves your problem.

    Cheers

    Ajay
    >-----Original Message-----
    >Example 'hello word' produce error (see below). Help me
    please!!!
    >
    >Thanks in advance,
    >
    >Primoz
    >
    >error description
    >Object reference not set to an instance of an object.
    >Description: An unhandled exception occurred during the
    execution of the
    >current web request. Please review the stack trace for
    more information
    >about the error and where it originated in the code.
    >
    >Exception Details: System.NullReferenceException: Object
    reference not set
    >to an instance of an object.
    >
    >Source Error:
    >
    >Line 1201:
    >Line 1202: OperationBinding FindHttpBinding(string
    verb) {
    >Line 1203: foreach (ServiceDescription description
    in
    >serviceDescriptions) {
    >Line 1204: foreach (Binding binding in
    description.Bindings) {
    >Line 1205: HttpBinding httpBinding =
    >(HttpBinding)binding.Extensions.Find(typeof(HttpB inding));
    >
    >Source File:
    >d:\winnt\microsoft.net\framework\v1.1.4322
    \Config\DefaultWsdlHelpGenerator.a
    >spx Line: 1203
    >
    >Stack Trace:
    >
    >[NullReferenceException: Object reference not set to an
    instance of an
    >object.]
    > ASP.DefaultWsdlHelpGenerator_aspx.FindHttpBinding
    (String verb) in
    >d:\winnt\microsoft.net\framework\v1.1.4322
    \Config\DefaultWsdlHelpGenerator.a
    >spx:1203
    >
    ASP.DefaultWsdlHelpGenerator_aspx.get_HttpPostOper ationBind
    ing() in
    >d:\winnt\microsoft.net\framework\v1.1.4322
    \Config\DefaultWsdlHelpGenerator.a
    >spx:441
    > ASP.DefaultWsdlHelpGenerator_aspx.get_ShowingHttpP ost
    () in
    >d:\winnt\microsoft.net\framework\v1.1.4322
    \Config\DefaultWsdlHelpGenerator.a
    >spx:456
    > ASP.DefaultWsdlHelpGenerator_aspx.__Render__contro l13
    (HtmlTextWriter
    >__output, Control parameterContainer) in
    >d:\winnt\microsoft.net\framework\v1.1.4322
    \Config\DefaultWsdlHelpGenerator.a
    >spx:1435
    > System.Web.UI.Control.RenderChildren(HtmlTextWrite r
    writer) +27
    > System.Web.UI.HtmlControls.HtmlContainerControl.Re nder
    (HtmlTextWriter
    >writer) +29
    > System.Web.UI.Control.RenderControl(HtmlTextWriter
    writer) +243
    > System.Web.UI.Control.RenderChildren(HtmlTextWrite r
    writer) +72
    > System.Web.UI.Control.Render(HtmlTextWriter writer) +7
    > System.Web.UI.Control.RenderControl(HtmlTextWriter
    writer) +243
    > System.Web.UI.Page.ProcessRequestMain() +1929
    >
    >
    >
    >
    >.
    >
    ajay Guest

  3. #3

    Default Web Service Error

    Im trying to add a web sevrice to my page and when i go to components press the
    + and say add using WSLD, then i put in thr URL for the wsdl as
    [url]http://computername:8159/wsschedule/wsschedule.asmx?WSLD[/url] and make sure that the
    proxy generator is set to .NET C# but when i press ok i get a sligt paurse
    then it replies unable to generate a proxy. can sombode please help? i have
    installed ADO.net SDK to try and help it but didnt seem to work

    clintons Guest

  4. #4

    Default Re: Web Service Error

    as with all macromedia products i have found listings of other people getting
    the same effect on there installs, it seems to be a random problem that a
    uninstall re-install of dreamweaver fixes.

    but as i dont have the time for that i simply used the wsdl.exe from the .net
    SDK and cut past the code it makes for you and wola webservice is running from
    the dw page!

    clintons Guest

  5. #5

    Default Web Service Error

    Hi Folks, I have written a small webservice in which one of the methods
    returns a nodelist. The file compiles OK, but when I try to run it I get the
    following error:
    "You must implement the Add(System.Object) method on System.Xml.XmlNodeList
    because it inherits from IEnumerable".
    Can anybody help??

    Shem Guest

  6. #6

    Default Re: Web Service Error

    Hello Shem,
    XmlNodeList is not serializable. Try returning an array of XmlNodes (XmlNode
    [])

    HTH
    Regards,
    Dilip Krishnan
    MCAD, MCSD.net
    dkrishnan at geniant dot com
    [url]http://www.geniant.com[/url]
    > Hi Folks, I have written a small webservice in which one of the
    > methods
    > returns a nodelist. The file compiles OK, but when I try to run it I
    > get the
    > following error:
    > "You must implement the Add(System.Object) method on
    > System.Xml.XmlNodeList
    > because it inherits from IEnumerable".
    > Can anybody help??

    Dilip Krishnan Guest

  7. #7

    Default Web Service Error

    Hi,
    I am new to working with webservices. This is my first program.

    I have the following error

    [RPC Fault faultString="Required parameter 'isbnSearchRequest' not found in
    input arguments." faultCode="EncodingError" faultDetail="null"]
    at
    mx.rpc.soap::Operation/http://www.adobe.com/2006/flex/mx/internal::invokePending
    Call()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\so ap\Operation.as:774]
    at
    mx.rpc.soap::Operation/send()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\rpc\so
    ap\Operation.as:688]
    at Function/http://adobe.com/AS3/2006/builtin::apply()
    at
    mx.rpc.soap.mxml::Operation/send()[E:\dev\3.0.x\frameworks\projects\rpc\src\mx\r
    pc\soap\mxml\Operation.as:167]


    The portions of the wsdl are

    - <xsd:element name="IsbnSearchRequest">
    - <xsd:complexType>
    - <xsd:sequence>
    <xsd:element name="bookName" nillable="true" type="xsd:string" />
    <xsd:element name="category" nillable="true" type="xsd:string" />
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    - <xsd:element name="IsbnSearchResponse">
    - <xsd:complexType>
    - <xsd:sequence>
    <xsd:element name="isbn" type="xsd:string" />
    <xsd:element name="author" type="xsd:string" />
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>

    <wsdl:message name="getISBNDetailsRequest">
    <wsdlart element="tns:IsbnSearchRequest" name="isbnSearchRequest" />
    </wsdl:message>
    - <wsdl:message name="getISBNDetailsResponse">
    <wsdlart element="tns:IsbnSearchResponse" name="isbnSearchResponse" />
    </wsdl:message>

    - <wsdlortType name="test">
    - <wsdlperation name="getISBNDetails">
    <wsdl:input message="tns:getISBNDetailsRequest" />
    <wsdlutput message="tns:getISBNDetailsResponse" />
    <wsdl:fault message="tns:faultMessageResponse"
    name="isbnFaultMessageResponse" />
    </wsdlperation>

    My mxml file is

    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
    <mx:WebService service="amazon" port="amazonSOAP" id="Test"
    wsdl="location of wsdl">
    <mxperation name="getISBNDetails">
    <mx:request>
    <bookname>Java 5</bookname>
    </mx:request>
    </mxperation>
    </mx:WebService>
    <mx:Panel x="10" y="10" width="475" height="400" layout="absolute"
    title="Amazon WebService">
    <mx:Button x="143" y="207" label="Test" click="Test.getISBNDetails.send()"/>
    <mx:Text x="133" y="82" text="{Test.getISBNDetails.lastResult.isbn}"
    width="188" height="79"/>
    </mx:Panel>
    </mx:Application>

    I am trying to call the webservice and display the output in the text control.

    thanks in advance.





    josh_aries Guest

  8. #8

    Default Re: Web Service Error

    Hi,

    As the error says, you need to have an isbnSearchRequest tag in your request.

    Maybe you can try to change your operation descriptor like this:

    <mxperation name="getISBNDetails">
    <mx:request>
    <IsbnSearchRequest>
    <bookname>Java 5</bookname>
    </IsbnSearchRequest>
    </mx:request>
    </mxperation>

    Another solution if you want to ease all your calls to web services is to use
    the WebServices introspection tool offered by Flex 3. It doesn't work every
    time but for simple wsdl it should be enough.

    Good luck,
    David


    David M.. Guest

Similar Threads

  1. Web service operation error
    By mlcox in forum Coldfusion - Advanced Techniques
    Replies: 0
    Last Post: May 2nd, 07:02 PM
  2. Error running web service
    By John in forum ASP.NET Web Services
    Replies: 3
    Last Post: August 10th, 12:03 AM
  3. error in web service... please help :(
    By Rodrigo Meneses in forum ASP.NET Web Services
    Replies: 4
    Last Post: February 20th, 10:57 AM
  4. Replies: 0
    Last Post: November 12th, 03:43 PM
  5. Error 711 and Error 5, Remote access connection manager service
    By Greenlee in forum Windows Networking
    Replies: 0
    Last Post: July 4th, 06:41 AM

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
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139