Skip to main content
Dec 17, 2010 12:39 AM UTC
Question

URLLoader doesn't work(IOError #2032) in AIR SDK version 2.5

Hi,

I'm troubling with URLLoader.load() method only in AIR SDK version 2.5.

Simply it doesn't work...

When 'load' method is called, the IOError below is raised

Error Event message:

>IOErrorEvent type="ioError" bubbles=false cancelable=false eventPhase=2 text="Error #2032: Stream Error. URL: http://localhost:8888/login/remoteLogIn?account=xxx" errorID=2032

# Additionaly, HTTPStatusEvent.status = 0

At the same code, same environment, it works if I chage AIR SDK version from 2.5 to Other(2.0/1.5)

#Flex SDK version is 4.1

The problem code is...

function initLoader():void{

        var url:String  = "http://hoge.com/servletName";

        var variables:URLVariables = new URLVariables();

         variables.account = "xxx";

        var request:URLRequest = new URLRequest(url);

         request.data = variables;

          var loader:URLLoader = new URLLoader(request)

         loader.load(_request);

        loader.addEventListener(Event.COMPLETE, completeEventListener);

        loader.addEventListener(HTTPStatusEvent.HTTP_RESPONSE_STATUS, responseListener);

        loader.addEventListener(HTTPStatusEvent.HTTP_STATUS, responseListener);

        loader.addEventListener(IOErrorEvent.IO_ERROR, responseListener);

        loader.addEventListener(SecurityErrorEvent.SECURITY_ERROR, responseListener);

}

function completeEventListener(e:Event):void{

     //some codes...

}

function responseListener(e:Event):void{

     //catch error event here.

}

I tryed another environment and another simple test code but it happens in any situation if AIR SDK version is 2.5.

Is anybody has same problem and has resolution of this problem?

With this problem, I can't access http server with AIR for Android.

Thanks.

This topic is closed to new replies. Start a new post to keep the conversation going.

82 replies

Innovatology
Participating Frequently
Feb 10, 2011 5:16 PM UTC

WORKAROUND:

Disable the network monitor before deploying to the device.

Choose Window > Show View > Other > Flash Builder > Network Montitor, then click the Disable Monitor button.

EXPLANATION:

I had this problem when I tried to access a webservice:

"faultCode:Server.Error.Request faultString:'HTTP request error' faultDetail:'Unable to load WSDL. If currently online, please verify the URI and/or format of the WSDL"

Investigating the FaultEvent > [inherited] > Message revealed the following error:

Error #2032: Stream Error. URL: http://localhost:37813/<service url>?WSDL?hostport=<server name>&https=N&id=<id>

That is not the direct URL to my webservice. It seems to be modified by the network monitor to be able to catch the network I/O of the device during debugging. As far as I can see there are two problems: 1) it doesn't work when you debug on the device and 2) it is not removed when you deploy.

STEPS TO REPRODUCE:

  1. create an AIR for Android app
  2. add a webservice
  3. call the webservice
  4. enable network monitor
  5. debug on or deploy to device

Cheers,                  - Jon -

http://www.webbsites.nl

Translate
Participant
Jan 23, 2011 5:35 AM UTC

I think that is a cache issue. When the URLLoader or HTTPService are using the browser cache you will get this error.

You can  clear the browser cache to test and  configure any no-cache policy in your  middleware (php,asp,java, etc),

regards,

Jhon Carrillo

@jhoncarrillo

Translate
Jan 23, 2011 10:58 AM UTC

the thread is about AIR sdk, so it's about AIR version not browser

Translate
Jan 21, 2011 11:17 AM UTC

I guess you must change Flex SDK version from 4.x to 3.x

I can send URL Variables in Flex SDK 3.5 and Air SDK 2.5.

Translate
Participating Frequently
Jan 21, 2011 11:22 AM UTC

But I am using Flash CS5 ,not even have linked Flex SDK libs

Translate
Participating Frequently
Jan 21, 2011 10:37 AM UTC

Please, could you provide a workaround to

send and load variables to a remote server using 2.5?

Regards

Translate
Jan 19, 2011 5:24 PM UTC

Any news about this thread?

Translate
chris.campbell
Legend
Jan 20, 2011 11:55 PM UTC

A potential fix was recently checked in and we're in the process of testing.  Assuming the fix addresses the issue, this will show-up in our next release.  The expect release date for this is within the next several weeks (mid to late March).

Thanks,

Chris

Translate
Participant
Jan 21, 2011 1:28 AM UTC

Thanks for the update and potential timeline.

Regards,

Rajesh

Translate
Participant
Jan 8, 2011 5:19 AM UTC

i got this problem in XP and Windows 7, and i requested was a JSON API.

Translate
Participating Frequently
Jan 1, 2011 4:57 AM UTC

I'm also getting this exact same issue, which is breaking a bunch of code. Only happens in 2.5

Translate
chris.campbell
Legend
Jan 7, 2011 9:35 PM UTC

Hi guys,

Sorry for the delay.  I'll take a look into this and let you know what I find.

Chris

Translate
chris.campbell
Legend
Jan 7, 2011 11:11 PM UTC

Hi guys,

I've been unable to reproduce this problem on either Mac 10.6.6 or Windows 7 x64.  I'm using Flex 4.1 and AIR 2.5.  Would anyone be willing to share their project that illustrates the problem?  I'm attaching my sample project to this post if you'd like to modify it appropriately instead.

Thanks,

Chris

Translate
Participant
Dec 24, 2010 2:49 AM UTC

yes, i got a same issue...

Translate
Dec 24, 2010 5:02 AM UTC

After all, I stopped to use Flex SDK version4.1 + AIR SDK version 2.5.

I found that in stuation of Flex SDK 3.5 + AIR SDK2.5, It's not appeared.

And in Flex4.5 + AIR2.5, it's also OK  though not released yet now.

It may be better update SDK(and Enomouse Code I wrote for 3.5) to 4.5.not to 4.1.

Thanks.

Translate