Topic: File operation on usb flash stick

I am really new to actionscript.  It is possible to create, open, read, write and delete text file on usb flash stick using actionscript ? If not, then is it possible to call these commands via linux operating system ?

thanks

Re: File operation on usb flash stick

We've added functions to Actionscript to read and write text files, however, that capability is reserved to movies that are run directly on the device, not conventional chumby widgets, that come from the network.

The reason for the restriction is that it's obviously very poor security to have an application (like a Flash movie) to come onto your machine, read the files, and then upload them to the Internet.  That's the most fundamental type of malware there is.

If you're interested in making a local movie that can read and write files, first you need to look at this page.

Here's an Actionscript 2 example:

import com.chumby.ChumbyNative;

ChumbyNative._putFile("/tmp/hello.txt","Hello, world\n");
if (ChumbyNative._fileExists("/tmp/hello.txt")==1) {
   var fileContents:String = ChumbyNative._getFile("/tmp/hello.txt");
   ChumbyNative._unlink("/tmp/hello.txt");
}