[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Batch Publishing in Flash JSFL

Posted on 2009-07-15
1
Medium Priority
?
478 Views
Last Modified: 2012-05-07
Hi Folks,

I have multiple FLA's in a folder. I want all the FLAs to be published to Flash Player 9 and AS2 and sound set to 48 kbps.

How do I do it with JSFL. Any code help is appreciated.

Thanks

RG
0
Comment
Question by:rgarimella
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 9

Accepted Solution

by:
danyul_c earned 2000 total points
ID: 24887749
First of all you will need to set your publish settings up as an xml file. (just create them in flash then save/export them, i forget the exact option)

Then try the code I've put below for your jsfl.

Please don't have anything open that you have not saved because I've written this to close everything. It will also not prompt to save changes after publishing each doc.

This is also all off the top of my head. I use this stuff at work and haven't written one for a while. The ony thing that *may* note work is the line where it says var doc = fl.openDocument becuase I'm not sure if the file list returns just the file names OR the entire URI for that file.

Let me know ;)
var folderUri  = 'file:///C|/temp/flas/*.fla"'
var publishXml = 'file:///C|/temp/publishsettings.xml';
var fileExt    = '*.fla';
var fileList   = FLfile.listFolder(folderUri, 'files');
 
fl.closeAll(false);
 
for (i = 0; i < fileList.length; i++) {
  var doc = fl.openDocument(folderUri + fileList[i]);
  doc.importPublishProfile(publishXml);
  doc.publish();
  doc.close(false);
}

Open in new window

0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Recently, I was asked to recommend a tracking system to be implemented on a clients website. As the entire site was built on flash, my first thought was to suggest custom built tracking system. However, our company at that point of time didn't h…
In my long career of working as an actionscript developer, I had spent sleepless night often working hard to solve some small problems which actually took a lot of my development time; later found out the solutions to be a line or two. Here are s…
The goal of the tutorial is to teach the user how to select which audio input to use. Once you have an audio input plugged into the laptop or computer, you will go into the audio input settings and choose which audio input you want to use.
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question