issButArray[i].setStyle("icon","@Embed(source='icons/more.gif')");

Type Coercion failed: cannot convert "@Embed(source='icons/more.gif')" to Class?

- New error?

--- In flexcoders@yahoogroups.com, Robert VanCuren Jr <robert.vancuren...@...> 
wrote:
>
> you need to use the setStyle method because icon is a style not a property.
> 
> myButton.setStyle("icon", source);
> 
> On Mon, Mar 15, 2010 at 8:20 AM, criptopus <sd_br...@...> wrote:
> 
> >
> >
> > // Add TLink To Issue Box
> > issButArray.push(new Button());
> > issButArray[i].icon="@Embed(source='icons/more.gif')";
> > issHbxArray[i].addChild(issButArray[i]);
> >
> > Error :
> >
> > Cannot create property icon on mx.controls.Button
> >
> > how do I set a buttons icon programatically?
> >
> > - Stephen
> >
> >  
> >
>


Reply via email to