|
|||
|
I want to be able to save text to a text file from Ffish in a way that flash can read.. My current script is:
var textArea = FlashPlayer.getVariable("notes_txt.text"); var myfile = new Stream("notes.txt"); myfile.write("&myVar"+FlashPlayer.getVariable("i") +"="+textArea); myfile.close(); And this works, but it glitches sometimes, i.e.: Writes over other text, and adds a square shaped symbol. I use SWFKit 2.2. |
|
|||
|
The text may contain special characters. Can you please send us (to support@swfkit.com) some text that causes problem?
|
|
|||
|
Sure. The simple way is to save variables like "var1=hello&var2=world". e.g.
Code:
var f = new FileStream(getAppDir() + "output.txt", "w");
f.write("var1=" + FlashPlayer.getVariable("var1") + "&var2=" + FlashPlayer.getVariable("var2"));
f.close();
|
|
|||
|
That's pretty much like what I'm doing already, unless I didn't understand you. Can swfkit overwrite only the variable in a text file I tell it too? Oh yeah, and the charector that shows up is like this, except it's a complete square: []
|
![]() |
Was this information helpful? Yes No
| Thread Tools | |
| Display Modes | |
|
|