13 Replies Latest reply on Feb 18, 2010 4:28 AM by abaki

    HTTP Request to ASP.NET web service application


      hi there,


      I have implemented a http request to php to get some xml results. it's done. now I am trying to implement similar service for asp.net web service application. I simply write an asp.net web service application that returns xml file as below.



          public class Service1 : System.Web.Services.WebService
              public  XmlDocument GetResults()
                  XmlDocument doc = new XmlDocument();
                  return doc;



      when I run that application it opens a browser page that contaions list of operations of my implementation. In this case there is only GetResults operation. to see the results of that operation I need to click invoke button which sends a post request to an url as below


      <form target="_blank" action='http://localhost:4070/Service1.asmx/GetResults' method="POST">                      
       <input type="submit" value="Invoke" class="button"></td>


      and from flash builder, I have implemented a http service with post method. when I say test the operation, it shows the result as text.


      the problem is that I cannot not actually use that service, cannot bind to a textarea. it gives that error


      HTTP request error
      Error: [IOErrorEvent type="ioError" bubbles=false cancelable=false eventPhase=2 text="Error #2032: Stream Error. URL: http://localhost:4070/Service1.asmx/GetResults"]. URL: http://localhost:4070/Service1.asmx/GetResults



      and I want it to return the exact xml file, from another discussion I solved that problem for php, simply from action script I get the service operation option and update its operation.serializationFilter and operation.resultFormat. but in this case it also gives error for those properties.


      any recommondations for me?