problem | |
adobe flex4 AS3.0, filestraem (air) How to write a file where the application is located | the mystery "fileWriteResource" hidden error | how to write files in applicationDirectory (where is not allowed) [tested in windows only] --- > page by dennis | |
solution | |
How to write a file where the application is located in the follow example, the variable "filename" is String and has as value the the file name without path, i.e.: "sample.txt" the follow code doesn't work, produces an error "fileWriteResource" that is not even thrown! var newFile:File=File.applicationDirectory.resolvePath(filename); use the follow code: var newFile:File=File(File.getRootDirectories()[0]).resolvePath(File.applicationDirectory.nativePath+File.separator+filename); //I am not kidding... it is working |
Information technology (it) often FAILS! Let's solve it. Problems and solutions on areas: Adobe's Flex, PHP, Delphi, Visual Studio, Windows, intranet, internet, popular applications, hacks, cheats techniques and much more; so enjoy your fail!!!
Thursday, 28 April 2011
flex, air, How to write a file where the application is located
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment