URLLoader Error #2032: Stream Error

0

This error can be caused by requesting a URL that is over the maximum length supported by Internet Explorer, which is 2083. This can be confusing, because if you copy a URL you are trying to load in Flex with a URLRequest into Internet Explorer, IE will truncate the URL itself, and appear to load properly.

This is especially important for REST API's that can take a long string variable.

The following code will avoid this issue.

var URL_MAX_LENGTH:int = 2083;
var request:URLRequest = new URLRequest(url.substr(0, URL_MAX_LENGTH));

[www.brighthub.com]

Labels:
Loading related posts...
Reactions: 

0 comments:

Post a Comment

2010 WEBSITE20. All rights reserved.