Got it working by using
[Embed("srcimage")]
protected const img:Class;
bitmapFill=new BitMapFill();
bitmapFill.source=srcImge;
rect.fill=bitMapFill;
On Fri, May 6, 2011 at 12:38 PM, Thulasi <[email protected]> wrote:
> Hi,
>
> I am trying to build an Action Script component and has an issue while
> assigning Bitmap fill to fill property of rectangle??
>
> how to use BitMap image and assign it to fill propertyin Action Script
> Code???
>
> i am attaching My code in MXML here:
>
> MXML:
> <s:Rect width="100%" height="100%">
> <s:fill>
> <s:BitmapFill source="@Embed('assets/background_row.png')" />
> </s:fill>
> <s:stroke>
> <s:SolidColorStroke color="#474747"/>
> </s:stroke>
> </s:Rect>
>
>
> AS:
>
> rect.fill=new SolidColorStroke(0x474747);
>
>
>
> thanks
> Thulasi.
>
>
>
>
--
You received this message because you are subscribed to the Google Groups "Flex
India Community" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/flex_india?hl=en.