As a part of flash application, I'm trying to store recorded files automatically to a specific path on users computer hard disk without they be aware. Is there a way to create directory in actionscript?
2 Answers
If you are using Flash in a web browser, for security reasons there is not. the only option to store something locally within a web browser is to use shared objects (kind of like cookies), but this is likely not what you want.
If you are not in a web browser you can use either AIR or a third party wrapper such as Multidmedia Zinc (for an additional cost).
File options for AIR can be found here: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/filesystem/File.html
File options for Zinc can be found here: http://www.multidmedia.com/support/livedocs/zinc/4.0/
EDIT
Since in your comment it sounds like your running in a web browser, you should leave it at simply streaming it to your server. If they have no internet connection there is no other good option other than live streaming using URLRequest
, that is, if you are within a web browser.
Here is some additional reading on this subject:

- 1
- 1

- 11,370
- 8
- 38
- 54
-
But my application is a part of online web activity. User should record his voice and the end of work upload recorded voice.Because of slow internet connection, can not stream to sever directly. – Amirhosein Jul 01 '13 at 14:07
There's a tutorial at http://hub.tutsplus.com/tutorials/create-a-useful-audio-recorder-app-in-actionscript-3--active-5836?request_uri=%2Ftutorials%2Factionscript%2Fcreate-a-useful-audio-recorder-app-in-actionscript-3 which does exactly what you want. Ignore the timeline-driven approach if you wish.
It uses the micrecorder library from https://code.google.com/p/micrecorder/ which records the audio and offers a file for the user to download at the end.

- 1,594
- 1
- 8
- 17
-
OK thank, this app ask from user where save the file.I'm thinking how change this that save into predefined particular place without asking from user. – Amirhosein Jul 01 '13 at 14:35
-
If you want to store at a predefined location then simply use the SharedObject class to store the data locally. You'll have to live with the file size limitation that the user may have placed on their computer. – Pranav Negandhi Jul 01 '13 at 14:39