import flash.filesystem.File; /** * 打开运行外部文件 * @param _pathUrl */ public static function openFile(_pathUrl:String) { var file:File = new File(_pathUrl); file.openWithDefaultApplication(); } //延伸 var dir:File = File.applicationDirectory; //应用程序安装目录 var dir:File = File.getRootDirectories(); //文件系统根目录 var file:File = File.userDirectory; //指向用户文件夹 var file:File = File.documentsDirectory; //指向用户文档文件夹 var file:File = File.desktopDirectory; //指向桌面 var file:File = File.applicationStorageDirectory; //指向应用程序存储目录 var file:File = File.userDirectory; file = file.resolvePath(“Mousebomb”); trace(file.nativePath);