# Using flash to write to a text file

**URL:** <https://forum.kirupa.com/t/using-flash-to-write-to-a-text-file/200491>\
**Category:** flash\
**Created:** [September 12, 2006, 5:28pm UTC](https://forum.kirupa.com/t/using-flash-to-write-to-a-text-file/200491 "2006-09-12T17:28:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![AGKbrian](https://avatars.discourse-cdn.com/v4/letter/a/96bed5/32.png) [@AGKbrian](https://forum.kirupa.com/u/AGKbrian)\
**Post date:** [September 12, 2006, 5:28pm UTC](https://forum.kirupa.com/t/using-flash-to-write-to-a-text-file/200491/1 "2006-09-12T17:28:20Z")

</div>

So here is what i’m working with. I built a quiz for teachers to use so all they would have to do is edit a text file and then flash would read the file and generate the quiz based off it. The problem i have is that a few of the teachers are having problems editing the text file in the correct way. I wrote this flash movie to save the variables to a text file. I read somewhere that fscommand - save dosent work anymore. Is there some other way to have it write a text file to the local machine? The swf would be saved on their machines.

```auto

function exportVar() {
    for (var i = 0; i<plantArray.length; i++) {
        scientificName* = plantArray***;
        commonName* = plantArray*[i+1]*;
        fileName* = plantArray**[i+1];
    }
    fscommand("save","plantInfo.txt")
}

```
