Thanks Matt.

However the statement you given also doesn't work.
I also tried following statement to make sure the name of default
"moveEffect".

trace(mx.core.Application.application.canvas1.viewstack1.panel1.viewstack2.selectedChild.childDescriptors[0].getStyle("moveEffect");

This always returns 'undefined' even though I set default moveEffect
on the MXML file.


I really am confused....
pls give me any clue....


Thanks,
Keishichi


--- In flexcoders@yahoogroups.com, "Matt Chotin" <[EMAIL PROTECTED]> wrote:
>
> Try this?
> 
>  
> 
> Application.application.canvas1.viewstack1.panel1.viewstack2.selectedChi
> ld.setStyle("moveEffect", "b"); 
> 
>  
> 
> ________________________________
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of keishichi2001
> Sent: Wednesday, October 26, 2005 3:35 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] set Effect at runtime
> 
>  
> 
> My Flex application is based on Cairngorm 0.99.
> Main application includes several custom components and those have 
> own ViewHelper to render themselves.
> 
> Let's assume two of custom components, CompA and CompB.
> CompA has a <mx:Image> in it, and it has moveEffect setting.
> CompA also has definition of several <mx:Effect>.
> ie)
> <mx:Effect name="a" ... />
> <mx:Effect name="b" ... />
> 
> I'd like to change this effect to another one from a ViewHelper of 
> CompB.
> To accomplish this, I tried following code.
> 
> =====
> ...
> var curImage:mx.controls.Image = 
> mx.core.Application.application.canvas1.viewstack1.panel1.viewstack2.s
> electedChild.childDescriptors[0];  // Image object
> 
> curImage["moveEffect"] = "b";
> ...
> =====
> 
> It seems that the moveEffect isn't changed, and no error at runtime.
> 
> Am I wrong on my code?
> Does anyone have good solution for this issue?
> 
> 
> Thanks,
> Keishichi
> 
> 
> 
> 
> 
> 
> 
> 
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives:
> http://www.mail-archive.com/flexcoders%40yahoogroups.com 
> 
> 
> 
> 
> ________________________________
> 
> YAHOO! GROUPS LINKS 
> 
>  
> 
> *      Visit your group "flexcoders
> <http://groups.yahoo.com/group/flexcoders> " on the web.
>         
> *      To unsubscribe from this group, send an email to:
>        [EMAIL PROTECTED]
> <mailto:[EMAIL PROTECTED]> 
>         
> *      Your use of Yahoo! Groups is subject to the Yahoo! Terms of
> Service <http://docs.yahoo.com/info/terms/> . 
> 
>  
> 
> ________________________________
>








------------------------ Yahoo! Groups Sponsor --------------------~--> 
Fair play? Video games influencing politics. Click and talk back!
http://us.click.yahoo.com/T8sf5C/tzNLAA/TtwFAA/nhFolB/TM
--------------------------------------------------------------------~-> 

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to