View Full Version : JSFL to export FLA with different publish settings

03-02-2006, 03:01 PM
Does anyone know if this is possible? I am new to JSFL, so please be easy on complex answers - I really just need to know if anyone has done anything like this before. What I need to do is export 1 (or preferably a batch) of FLA files with 3 different publish settings: e.g. animation1.fla to animation1_WEB28.swf (with audio quality set to 16kbps), animation1_WEB56.swf (audio set to 32kbps) and animation1_WEB100.swf (audio set to 64kbps).

HELP! (will earn me brownie points at work, and you, satisfaction!)


03-03-2006, 07:00 PM
I haven't actually done this, but I think you can use

fl.openDocument("file:///C|/folder name/document name");

to open the document

fl.getDocumentDOM().currentPublishProfile = "profile name";

to set the publish profile you want to use, then

fl.saveDocument(fl.getDocumentDOM(), "file:///C|/folder name/document name.fla"));

to save the file and then close the file without a save prompt with

fl.closeDocument(fl.getDocumentDOM(), false);

Take a look in the Flash help file in the Extending Flash section for more info.

03-14-2006, 10:49 AM
Hi everybody

i m very new for jsfl. i want run jsfl file at button click event can i? if so, How?

i m awaiting for ur resp


03-14-2006, 04:53 PM
You can assign keyboard shortcuts to commands from the edit->keyboard shortcuts menu. If you're using the Macromedia Standard shortcuts then you need to duplicate that set first.

If you want to run scripts at mouse-clicks, then you need to make a custom tool, which is a bit harder than making custom commands.

03-16-2006, 08:25 AM
..thanks for the (possible) solution - I will try and let you know if I can get it to work...


11-15-2008, 10:40 AM
..thanks for the (possible) solution - I will try and let you know if I can get it to work...


Isn't it annoying how no one ever finishes posts like these off? I don't suppose anyone has a JSFL for this that will work and they are willing to share? Basically I want my flash to publish into a mirrored directory that is just reserved for the build so that a file
rootDrive/directory/source/(anyfurther directories/)thisDoc.fla
would publish to
rootDrive/directory/build/(anyfurther directories/)thisDoc.swf