RE: [Flashcoders] Changing display index on the stage

2010-05-05 Thread Robert Leisle
Hi, //Assumes mc1 is on the stage and has linkage set to mc1 var mc2:MovieClip = new MovieClip(); addChild(mc2); addChild(mc1); hth, Bob -Original Message- From: [] On Behalf Of natalia

RE: [Flashcoders] Equivalent of setCharAt to change a character in a string

2009-07-14 Thread Robert Leisle
Does this not work for you? // Change the first instance only var myPattern:RegExp = /sh/; // Change all instances //var myPattern:RegExp = /sh/g; var str:String = She sells seashells by the seashore.; trace(str.replace(myPattern, sch)); // She sells seaschells by the seashore. Hth, Bob

RE: [Flashcoders] Equivalent of setCharAt to change a character in a string

2009-07-14 Thread Robert Leisle
a character in a string Thanks Robert - yes I am able to replace patterns but just wondered If simple way to change a particular character in a string based on the character index? Thanks Paul Sent from my iPhone On 14 Jul 2009, at 18:10, Robert Leisle wrote: Does this not work

RE: [Flashcoders] ReferenceError: Error #1065 issue

2009-06-22 Thread Robert Leisle
Thanks Mario! I actually found the solution to this. It was my own mistake, of course. I've got a base level swf loading in a child swf which contains the super class and subclass mentioned below. Turns out the loading swf also uses the super class, and I hadn't recompiled it in the process. It

[Flashcoders] ReferenceError: Error #1065 issue

2009-06-18 Thread Robert Leisle
Hi list, This should be simple, but for some reason refuses to cooperate. I'm working in AS3, CS3. I've got a super class (HsSegment) and a subclass (HsSegment_qtd1), both are public. In the super class are the definitions for many methods, including this definition: protected function

RE: [Flashcoders] swf paths...

2009-06-03 Thread Robert Leisle
Hi Maurice, How about sending it in as a URL variable when you load preloader.swf into the html page? In the HTML: object . param name=movie value=swf/preloader.swf?path=swf/ / ... embed src=swf/preloader.swf?path=swf/ .../ /object Then in preloader.swf: var

RE: [Flashcoders] swf paths...

2009-06-03 Thread Robert Leisle
(/); str = str.substring(slash+1, str.length); dot = str.lastIndexOf(.); filename = str.substring(0, dot); directoryLocation = _url.split(filename + .swf).join(); and setting it to frame 1. On Wed, Jun 3, 2009 at 2:15 PM, Robert Leisle wrote: Hi Maurice, How about sending

RE: [Flashcoders] Getting attributes out of a node with : in it

2009-02-09 Thread Robert Leisle
Check out the Namespace class, as it applies to XML, in the Flash docs. There's also a good explanation in this tutorial by Lee Brimelow: hth, Bob -Original Message- From:

RE: [Flashcoders] help stopping an external clip on as3

2009-01-16 Thread Robert Leisle
Hi Gustavo, Try this: var mc:MovieClip = myLoader.content as MovieClip; mc.stop(); or MovieClip(myLoader.content).stop(); Either one should work. hth, Bob -Original Message- From: [] On Behalf Of

[Flashcoders] What REALLY causes an IOError?

2008-11-03 Thread Robert Leisle
Hi all, I am trying to drill deeper into Flash player IOError handling in AS3, in order to distinguish different types of load failures when loading child swfs and data into a parent swf. For instance, I need to know, and react differently to, loads errors where the file is missing altogether vs.

RE: [Flashcoders] getting loader to work with security policy...

2008-09-09 Thread Robert Leisle
Hi Boyd, Yes, you'll need to do import flash.system.Security; to use the loadPolicyFile method. Also, in your crossdomain.xml, you'll need to include allow-access-from, or allow-access-from domain=* The way it is coded now will only allow the specific

RE: [Flashcoders] Re: How to avoid little blink while loading another movie

2008-09-02 Thread Robert Leisle
You could also load the SecondLine.swf slightly before you actually want to display it, but delay adding it to the display list until you do want to display it. var myUILoader:UILoader=new UILoader(); myUILoader.height=23.6; myUILoader.move(-17,-1); myUILoader.source=SecondLine.swf; Then at

RE: [Flashcoders] ColorPicker.selectedValue to #hex?

2008-07-24 Thread Robert Leisle
Hi Jason, Is something like this what you need? function dec2hex(input):String { var hex:Number; var stgHex:String = uint(input).toString(16); while (stgHex.length 6){ stgHex = 0+stgHex; } stgHex = 0x+stgHex; return stgHex; }

RE: [Flashcoders] E4X filtering strange behaviour

2008-07-21 Thread Robert Leisle
Hi Jason, This works for me: var testXML:XML = data topics topic title=Coldplays New Album / topic title=The Dark Knight / topic title=Arrested Development: The Movie /

RE: [Flashcoders] Firefox popup blocker and flash 9

2008-05-28 Thread Robert Leisle
This is probably not what your client wants to hear but the question has to be asked. Isn't Firefox popup blocker there for a reason? When blocking is active there is a message when a popup is attempted. Users have the choice to block or not, or to white-list your popups. I recommend allowing them

RE: [Flashcoders] Why isn't my TextField multiline? AS2

2008-05-07 Thread Robert Leisle
Hi Alistair, Try adding this to your code: tmpField.wordWrap = true; Hth, Bob -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Alistair Colling Sent: Wednesday, May 07, 2008 10:03 AM To: Flash Coders List Subject: [Flashcoders] Why isn't my TextField

RE: [Flashcoders] AS3 For loop proplem

2008-05-06 Thread Robert Leisle
Hi SJM, It looks like you're setting the persistent var, _mcName, to equal each _summaryElement[i].sumImg in turn as the loop progresses. That means that when the loop is finished, the value for _mcName will be a reference to _summaryElement[4].sumImg, the last clip being loaded. Since your

RE: [Flashcoders] A simple question for getting Object info.

2008-05-02 Thread Robert Leisle
Hi ACE, This works: var bookList:Object = { BOOK1:{isbn:155209328X,Price:$19.95.,Title:This is Book1 Title}, BOOK2:{isbn:0072231726,Price:$24.95.,Title:This is Book2 Title} }; for (var book:* in bookList) { trace(book); for (var i:* in bookList[book]) {

RE: [Flashcoders] Button addEventListener is cancelled out by my Timerfunction.

2008-02-25 Thread Robert Leisle
Hi Vlado, It looks like your button is probably on the timeline rather than make instantiated with code. Make sure your button exists before you do the addEventListener() on frame 25. Also, do you maybe have a key frame in the button layer at frame 65? If so, each key frame creates a new instance

RE: [Flashcoders] RangeError: Error #2006: The supplied index is out ofbounds.

2008-02-25 Thread Robert Leisle
Hi Anuj, According to Flash Help files for getChildAt(), this error is generated by getChildAt() when, RangeError - Throws if the index does not exist in the child list. Either your aa variable is not evaluating correctly inside the function or there is no child object at depth index 0 when the

Re: [Flashcoders] RE:Flashcoders] Extending Array Question

2006-04-18 Thread Robert Leisle
You could also do: var myArray:ArrayExtension = new ArrayExtension(); myArray.push(Hello, Goodbye, World); same result as doing them separately. [EMAIL PROTECTED] wrote: Thanks, that will work. So there is no definitive way to add the values all at once, i.e. [1,4,5,76,3] when extending

Re: [Flashcoders] LOADVARS not working IE

2006-03-21 Thread Robert Leisle
I had this same issue last month. Here's the advice I got (Thanks to Mark Llobrera) on this board. It was right on target for me. Hope it helps you too. You may want to check this posting: As I understand it, if the server is returning no-cache headers for

Re: [Flashcoders] Problem

2006-03-21 Thread Robert Leisle
You're defining the onRelease function before outside_btn.swf is loaded. Wrap your onRelease definition in an onLoadComplete function to solve your problem:

Re: [Flashcoders] String problems?

2006-03-06 Thread Robert Leisle
What is it you're trying to do? Your code is written correctly to get the result you described. Is that not the result you were after? Flash Mel wrote: I am writing this wrong: controller_mc.attachMovie(gallery_mc, gallery_mc, 50); theGallery = controller_mc.gallery_mc; gallery_contains =

[Flashcoders] SSL and Flash in IE6

2006-02-14 Thread Robert Leisle
Hello group, I've run searches in the archives, google and other groups and am unable to find a cause for this: I've built a very simple Flash MX (6) test swf file, uploaded it to an http server. Its only task is to load a small data file (.txt) from another server (same domain) through