this is a simple example of new feature in flash cs4 FileReference.save(). in this example i just create an html file using the rich text editor from http://mobilewish.com/applications/as3texteditor/. and save it using FileReference.save() to local file system . download rich text editor
Source File:http://anilmathew.info/flash/filerefer_example.fla
code sample
import flash.net.FileReference;
tt.input_txt=abc;
tt.scroller=scroller;
abc.addEventListener(MouseEvent.MOUSE_UP, tt.handleClick);
generate_btn.addEventListener( MouseEvent.CLICK, generateTEXT );
function generateTEXT( e:MouseEvent ) {
var texT:String=abc.htmlText;
var file:FileReference = new FileReference();
file.save(texT,"myfile.html");
}
Subscribe to:
Post Comments (Atom)
1 comments:
i did some filereference.load demo on my site: cs4 filereference demo
let me know what you think..
Post a Comment