List Info

Thread: RE: Scrolling dynamic text window with vars




RE: Scrolling dynamic text window with vars
country flaguser name
United States
2007-03-21 15:20:06
Oh yeah, easy peasy. In my example, I used a TextArea
component, since
it works just like the Output window in Flash.  Just write a
function
that always shows the same variables, i.e.:

//Assumes there is a TextArea component on 
//the stage with instance name "test":

function traceWindow(show:Boolean):Void
{
   test._visible = show;
   if(show)
   {
	//show variables:
	test.text = "nmyVar1: "+myVar1;
	test.text += "nmyVar2: "+myVar2;
	test.text += "nmyVar3: "+myVar3;
	test.text += "nmyVar4: "+myVar4;
	//size and position it:
	test.setSize(300, 600);
	test.move(10, 10);
	//optional: scroll to bottom always
	test.vPosition = test.maxVPosition;
	//always show on top when called:
	test.swapDepths(_level0.getNextHighestDepth());
   }
}

then call traceWindow(true) whenever you want it to show. To
hide it
call traceWindow(false).  Something like that.  Mine took
actual
messages, but you could hard code it for specific variables
like the
above example.

Jason Merrill
Bank of America  
GT&O Learning & Leadership Development
eTools & Multimedia Team


 

>>-----Original Message-----
>>From: flashnewbie-bounceschattyfig.figleaf.com 
>>[mailto:flashnewbie-bounceschattyfig.figleaf.com] On
Behalf 
>>Of Vaughn, David (Contractor) (J6B)
>>Sent: Wednesday, March 21, 2007 12:28 PM
>>To: Flashnewbie Mailing List
>>Subject: [Flashnewbie] Scrolling dynamic text window
with vars
>>
>>Hi all. After reading Jason's posts, I'm wondering
if I (a 
>>fairly new AS
>>coder) could build an on-screen window that would
hold about 
>>a dozen variables both within Flash and the
published SWF. 
>>What I'd like to do is populate that window with the

>>variables I need to track and have them update as
necessary. 
>>Before delivery I'd delete the window obviously so
it would 
>>just be a development tool. 
>>
>>Assuming it's not too difficult, what's a good way
to do this?
>>
>>Thanks!
>>___________________________________
>>David Vaughn
>>Northrop Grumman Information Technology
>>269.961.7158
>>david.vaughn.ctrdla.mil 
>>
>>_______________________________________________
>>Flashnewbiechattyfig.figleaf.com
>>To change your subscription options or search the
archive:
>>http://chattyfig.figleaf.com/mailman/listinfo/flashnewb
ie
>>
>>Brought to you by Fig Leaf Software
>>Premier Authorized Adobe Consulting and Training 
>>http://www.figleaf.com http://training.figleaf.c
om
>>
_______________________________________________
Flashnewbiechattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashnewb
ie

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.c
om

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )