[Flashjs] Size limit in amount of data sent to JS?

Alex MacCaw maccman at gmail.com
Fri Sep 21 14:53:16 PDT 2007


I had the same problem with transferring javascript using getUrl.
As far as I'm aware, the only way round the char limit is to either use
ExternalInterface or fscommand.
Alex

On 9/21/07, Al Deluca <alfred_deluca at harvard.edu > wrote:
>
> Hello,
>
> I'm developing a printing solution in Flash and coming up against what I
> believe to be a size limit in the amount of data that can be fed from a
> Flash movie to a JS function, but only in IE 6.0 (it works wonderfully in
> FF),on Win XP SP2. Wondering if anyone else has seen this. I did look over
>
> the archives of this list and didn't find anything about it in relation to
> the most recent version of the integration kit, and Google has given me
> some conflicting and outdated information regarding size limits. At least
> one resource has told me that there is no known size limit to data moved
> from Flash to a JavaScript function... Should I believe that? I have found
> that if I pass over a smaillish amount of text it does indeed work
> perfectly. If I exceed that smallish amount by a few characters, it
> breaks;
> it's as if the JS function is never called. Here is some code which shows
> the amount of text that breaks it:
>
> **from the movie/'s actionscript panel:** :
>
> import com.macromedia.javascript.JavaScriptProxy;
> var proxy:JavaScriptProxy = new JavaScriptProxy(_root.lcId, this);
>
> this.attachMovie("holder_mc", "holder_mc_in", 2);
>
> pagination_str="here is some text. here is some text here is some text.
> here is some text. here is some text. here is some text. here is some
> text.
> here is some text. here is some text. here is some text.here is some
> text..
> here is some text.here is some text.. here is some text.here is some
> text..
> here is some text.here is some text."; // this seems absurdly small (and
> delimiter free) to break FSCommand... could be a parsing problem or the
> .htmlText
>
> _root.holder_mc_in.tf_in.htmlText = pagination_str;
>
> this.print_bttn_in.onRelease = function() {
>         transferItemToJavaScript();
> }
>
> function transferItemToJavaScript():Void {
>      proxy.call("printFlash", _root.holder_mc_in.tf_in.htmlText);
> }
>
> ** from the hosting HTML page** :
>
> <script type="text/javascript"
> src="js/JavaScriptFlashGateway.js"></script>
> <script type="text/javascript" >
> <!--
> var uid = new Date().getTime();
> var flashProxy = new FlashProxy(uid, "gateway/JavaScriptFlashGateway.swf"
> );
>
> function printFlash(str){
>         //alert("here i am " + str )
>         alert("just confirm that the function has been called") // print
> button
> does nothing if text > ~ 250 characters
> }
> //-->
> </script>
>
> If anyone could offer some insight, I would greatly appreciate it.
>
> Thanks.
>
> oh, and I know what RTFM means, though I sometimes don't know which M to F
>
> R. Is there more in-depth documentation available?
>
> ----
>
> Al DeLuca
> Manager, Multimedia Development
> Educational Systems and Technology
> Harvard University
> alfred_deluca at harvard.edu
>
>
>
>
> _______________________________________________
> Flashjs mailing list
> Flashjs at osflash.org
> http://osflash.org/mailman/listinfo/flashjs_osflash.org
>



-- 
http://www.eribium.org | http://juggernaut.rubyforge.org |
http://www.aireofs.com | Skype: oldmanorhouse
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://osflash.org/pipermail/flashjs_osflash.org/attachments/20070921/38d9f1f7/attachment.html 


More information about the Flashjs mailing list