PDA

View Full Version : Launching a PDF using Flash MX


Gecko
09-24-2004, 11:57 AM
I have put a job together which consists of work sheets. My client wants them as pdf files on a CD but instead of the user opening the CD and being faced with lots of pdf files, they would prefer that there is a file on the CD which can be opened up (like a Flash Projector file) and then the user can then click a title wich will link and open a pdf file. I have created the projector file and then have done the following:

I have moved my projector file up to the root of the disk image. I have left the applescript named: Script_U62_1 in the sub folder along with the pdf called: U62_1.pdf. My applescript reads :
tell application "Finder"
open file "U62_1.pdf" of folder "fscommand" of disk "Big_Test"
end tell and It works fine.

The fscommand in Flash MX reads as follows:
on (press) {
fscommand("exec","Script_U62_1");
}

I have then saved my Flash MX file and have published it to the root of the disk image but when I run the projecor file nothing hapens.

The reason I am using the fscommand and not thr URL is because I don't want the web brouser to open unless someone knows how I can get the pdf to open within the web browser?

Somebody please help - this is driving me mad!

boyzdynasty
09-24-2004, 01:27 PM
Check out this thread...

http://www.actionscript.org/forums/showthread.php3?t=5843&highlight=pdf+files

Gecko
09-24-2004, 09:06 PM
I have already been here and have done everything they have said. Thank you anyway - your reply was much appreciated. I will keep on searching!

boyzdynasty
09-25-2004, 05:28 PM
sorry I couldn't be of much help.
never had to do that before...good luck.

arkanoid2k
10-01-2004, 04:25 AM
hi, there.
what you should do is create a folder named fscommand in your root directorie and create a batch file, which you execute with the button of your aplication.

eg: on (release) {
fscommand("exec", "batname.bat");
}

so, you should have inside your fscommand folder, the files you wish to open, and the .bat file.

inside the bat file you shoul tipe @start yourfile.pdf

good luck