CS5 Flash Prof: Looking for a Batch/Mass Publishing Plugin [closed]
We don’t allow questions seeking recommendations for开发者_开发问答 books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this questionI am working on a flash project that has many fla files associated with it. Is there a plug-in that will allow me to publish many flash files without me having to manually open and publish them myself. I know in Photoshop there is a batch processing of actions but was unaware if there was one for Flash.
Thank you.You can get away with a basic jsfl script:
var dir = fl.browseForFolderURL("select fla folder");//open a folder
var files = FLfile.listFolder(dir,"files");//get the files (note: NOT recursive!)
var filesNum = files.length;
fl.outputPanel.clear();
for(var i = 0 ; i < filesNum; i++){
if(files[i].substr(files[i].lastIndexOf(".")+1) == 'fla'){//look for fla's
var doc = fl.openDocument(dir+'/'+files[i]);
//toggle the comment on the prefered way of exporting
//doc.exportSWF(add your location here,useCurrentSettings?);
doc.publish();
//doc.testMovie();
fl.saveDocument(doc);
fl.closeDocument(doc,false);
fl.trace(files[i]+' done! ' +(i+1) + " of " + filesNum);
}
}
fl.trace('all done!');
Easiest way to use this is to create a new JavaScript Flash document in Flash CS5 and save it as BatchPublish.jsfl or something descriptive. This way, the file should default to the correct location on the file system and show in the Commands menu.
Once you run the command/script, it should prompt you for a folder with fla files and it will loop through the files, publish, then save and close. You can comment out the saving if it's not needed.
A google search should also provide you with good results.
HTH
精彩评论