Groups | Blog | Home
all groups > flash actionscript > march 2004 >

flash actionscript : how to... news section



boondocksaintMX
3/25/2004 11:57:18 PM
is this possible if so, how can i do that?
on the stage. box which will contain text from a txt or html file.
buttons on the side and when clicked, the content will load in the box that
before that had text in it.
if u need more expalantion of what i mean to help me. please say so.
jon j
3/26/2004 12:06:06 AM
Yes,
Read about LoadVars() in the help files
creativity06
3/26/2004 2:34:16 AM
To load text without a button..I would use this code..attach this to first
frame..make a dynamic text box..the instance name should be scroller..

loadText = new loadVars();
loadText.load("textfilegoeshere.txt");
//creating the loadVarsText function
loadText.onLoad = function() {
scrollbar.text = this.externalscrolling;
};

To load files with different buttons, go to this tutorial. All he used is this
code.

on (release) {
loadVariablesNum("textfilegoeshere.txt", 1);
}

Here is a good tutorial:
[L=Tutorial on Loading External Text
Files]http://www.kirupa.com/developer/mx/multiple_dynamictext.htm[/L]
boondocksaintMX
3/26/2004 5:29:25 AM
the code AS u told me got me this error does
**Warning** Scene=Scene 1, layer=Layer 1, frame=1:Line 1: The identifier
'loadVars' will not resolve to built-in object 'LoadVars' at runtime.
loadText = new loadVars();

Total ActionScript Errors: 1 Reported Errors: 1
AddThis Social Bookmark Button