[flexcoders] Re: Problem with HTTPService ResultEvent.RESULT not firing

2007-08-31 Thread williamkusumo
Okay, I haven't found a solution yet, but after some debugging, turns
out everything boils down to the Content-type that the webservice is
returning. The webservice is returning text/plain result, not XML (I
did my own test, if the service returns text/xml, everything works as
it should). I tried setting HTTPService.RESULT_FORMAT_TEXT to
resultFormat, it still doesn't work. The request is successful (HTTP
status 200), but it won't trigger ResultEvent...

This is frustrating...

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Hello!
 
 I am calling a webservice that does something and return HTTP status
 (either success or fail) that's it, no data whatsoever is returned. I
 need to do something when I got the response back but for some reason,
 ResultEvent.RESULT is not firing if there is no data being returned by
 the webservice. Is there another event I can listen to that'll do this?
 
 Appreciate the help! Thanks!





[flexcoders] Re: Problem with HTTPService ResultEvent.RESULT not firing

2007-08-31 Thread williamkusumo
Yes, found it! Somewhere along my ResultEvent callback function, I
have a conversion to XML that is failing. Damn, gotta learn to put try
catch in everything...


--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Okay, I haven't found a solution yet, but after some debugging, turns
 out everything boils down to the Content-type that the webservice is
 returning. The webservice is returning text/plain result, not XML (I
 did my own test, if the service returns text/xml, everything works as
 it should). I tried setting HTTPService.RESULT_FORMAT_TEXT to
 resultFormat, it still doesn't work. The request is successful (HTTP
 status 200), but it won't trigger ResultEvent...
 
 This is frustrating...
 
 --- In flexcoders@yahoogroups.com, williamkusumo williamkusumo@
 wrote:
 
  Hello!
  
  I am calling a webservice that does something and return HTTP status
  (either success or fail) that's it, no data whatsoever is returned. I
  need to do something when I got the response back but for some reason,
  ResultEvent.RESULT is not firing if there is no data being returned by
  the webservice. Is there another event I can listen to that'll do
this?
  
  Appreciate the help! Thanks!
 





RE: [flexcoders] Re: Problem with HTTPService ResultEvent.RESULT not firing

2007-08-31 Thread Tracy Spratt
First, I think you are you using the term webservice generically, and
not in its specific Flex WebService - SOAP protocol sense, right?

 

And to be sure I understand your situation, your http service is
returning an empty string, and the result event firing behavior is
different for different content types?

 

You might experiment with URLLoader.  As I understand, HTTPService uses
this under the covers.  Perhaps its result event will fire in this
condition.  If so, this might be a bug.  Perhaps we should google it.

 

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of williamkusumo
Sent: Friday, August 31, 2007 3:56 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Problem with HTTPService ResultEvent.RESULT
not firing

 

Okay, I haven't found a solution yet, but after some debugging, turns
out everything boils down to the Content-type that the webservice is
returning. The webservice is returning text/plain result, not XML (I
did my own test, if the service returns text/xml, everything works as
it should). I tried setting HTTPService.RESULT_FORMAT_TEXT to
resultFormat, it still doesn't work. The request is successful (HTTP
status 200), but it won't trigger ResultEvent...

This is frustrating...

--- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
, williamkusumo [EMAIL PROTECTED]
wrote:

 Hello!
 
 I am calling a webservice that does something and return HTTP status
 (either success or fail) that's it, no data whatsoever is returned. I
 need to do something when I got the response back but for some reason,
 ResultEvent.RESULT is not firing if there is no data being returned by
 the webservice. Is there another event I can listen to that'll do
this?
 
 Appreciate the help! Thanks!