Are you using AIR? If not, you can't do this locally.

Otherwise you can sent the data to the server and have the server replace the 
file. These posts should help you on your way:
http://www.quietless.com/kitchen/dynamically-create-an-image-in-flash-and-save-it-to-the-desktop-or-server/
http://www.elctech.com/tutorials/transform-bitmapdata-into-jpegs-as3-jpgencoder-rails-rmagick
http://www.sephiroth.it/tutorials/flashPHP/amfphp_bytearray/index.php

--- In flexcoders@yahoogroups.com, "James" <garymoorcroft_...@...> wrote:
>
> In my app I have a tilelist which gets it's data and images from a data 
> provider 'myTileListAArrayCollection'. I have a function which takes a 
> snapshot of a component and saves it as a bitmap. What I want is for this 
> bitmap to be saved so that it overwrites an image jpg I have defined in a 
> class 'abcnewspicture'. Obviously this will mean that the tilelist will have 
> default images but then once the snapshot is taken and replaces the jpg the 
> image within the tilelist will change dynamically. Here's the code which sets 
> the object of the array collection in question after the snapshot has been 
> taken.
> 
> myTilelistAArrayCollection.setItemAt({id:"yrhe", label:"reyery", 
> icon:"abcnewspicture"}, 0);
> 
> Can anyone help me out on saving this bitmap as a jpg so that it overwrites 
> an existing jpg in my assets/images folder of the app? I've searched and 
> can't find a solution for this anywhere.
>


Reply via email to