Load text from external text file ..

Posted by webstyler 
Load text from external text file ..
November 12, 2008 01:56PM
Hello

We would like to load on dynamic textarea a text write on .txt file (or maybe xml)

Any line/row maybe used as individual messagge and show when last hide..

There is any tutorial or example for make this in flasheff ?

Thanks
Re: Load text from external text file ..
November 13, 2008 06:55AM
The FlashEff component must be applied directly on a TextField (not TextArea) if you want to use it to animate text. As for making sequential animations, we don't really have a tutorial for that, but you can check out the help pages for the properties, methods and events of the component: http://www.flasheff.com/howtouse/.

For sequential animations you should turn off the auto play feature of the component (set the showAutoPlay and hideAutoPlay properties to false) so you can start the animations by code (use the show() or hide() methods). If you want to know when a transition starts and ends, you can use the FLASHEFFEvents.TRANSITION_START and FLASHEFFEvents.TRANSITION_END events (check the currentTransitionType property to see if the current transition is a "show" transition or a "hide" transition).
Re: Load text from external text file ..
April 01, 2009 02:24AM
Kind of related, I have two questions: 1. Can you apply FlashEff to dynamic text loaded into text fields in Flash (sounds like you can!) and 2. AS3 (required for FlashEff) breaks the traditional LoadVars way of importing outside data into Flash-- is there a good tutorial (or sample .fla) somewhere on loading text into flash?

I've been testing FlashEff tonight and am amazed-- what a terrific product!
Re: Load text from external text file ..
April 08, 2009 08:23AM
I have the same question: can you apply FlashEff to a dynamic text taken (for instance) from an XML file? Thanks
Re: Load text from external text file ..
April 10, 2009 07:11AM
I have the strangest error. Everything works fine in firefox and safari, but PC ie I have problems.

All I am doing is dynamically adding text to the textfield which has the FlashEff effect. In IE 7 the field displays "error"

Here's my actionscript:

slogan.InstanceName_6.text ="new value"
Re: Load text from external text file ..
April 10, 2009 07:11AM
You will need one textfield that has all the characters that you will use embeded and the add the FlashEff component on that textfield. Load the xml files and take the text from the xml and put it in( it would be something like this yourTextField.text = xmlText) Don't start the transition until the xml is loaded 100%.
Re: Load text from external text file ..
April 10, 2009 07:29AM
Actually I finally figured it out.

I was repositioning the movieclip according to stagewidth also. That made it error in IE7 not mac. I think somehow it was repostioning before the vars loaded somehow. Weird that it was only IE

Here's the bad:

slogan.x = stage.stageWidth;
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;

function resizeListener (e:Event):void {
slogan.x = stage.stageWidth;
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;
}
stage.addEventListener(Event.RESIZE, resizeListener);
var allFlashVars:Object = LoaderInfo(this.root.loaderInfo).parameters.pagetitle
slogan.InstanceName_6.htmlText = String (allFlashVars);

Here's the good:

var allFlashVars:Object = LoaderInfo(this.root.loaderInfo).parameters.pagetitle
slogan.InstanceName_6.htmlText = String (allFlashVars);

slogan.x = stage.stageWidth;
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;

function resizeListener (e:Event):void {
slogan.x = stage.stageWidth;
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;
}
stage.addEventListener(Event.RESIZE, resizeListener);


still a little strange the difference of browsers
Sorry, you do not have permission to post/reply in this forum.