Current location: Hot Scripts Forums » General Web Coding » Flash & ActionScript » How to Convert PowerPoint to Flash Manually


How to Convert PowerPoint to Flash Manually

Reply
  #1 (permalink)  
Old 01-05-08, 05:06 AM
WPeterson's Avatar
WPeterson WPeterson is offline
New Member
 
Join Date: Jan 2008
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Lightbulb How to Convert PowerPoint to Flash Manually

Flash has some advantages and this tutorial guides you how to convert PowerPoint to Flash presenations manually.

Converting PowerPoint to Flash would absolutely be a good choice to distribute your bulky PowerPoint presentations.

You can do the whole PowerPoint to Flash conversion manually or with professional applications.

First, you'll need to prepare the PowerPoint files. Make sure you are not using any complicated gradients or animations. These will be interpreted poorly when they are brought into Flash. Also, make sure there are no objects that fall outside the confines of the slide area. This will ensure that all the slides align correctly when they are imported to Flash. Now, save a copy of your presentation without any background images. You may want to also choose a contrasting background color to easily see the content of each slide. You all import the background images into Flash at a later time.

Second, choose File > Save As... from your PowerPoint document and save the presentation as a Windows Metafile (*.wmf). This will save your entire presentation as a sequence of files. WMF files keep all text.

Next, create a new Flash Document and resize the Stage to 720 x 540. Change the background color to black. Choose File > Import > Import to Stage... and import the first WMF file. When asked to import all of the images in the sequence, choose Yes. This will place each slide from your presentation onto a sequence of frames.

Then, create a new layer under the slides layer and import the images to use for your background. You'll probably need two images, one for title slides and one for the regular slides.

Now it's time for some manual labor. You'll need to go through every frame of the movie and delete the solid background shape from your slides layer. Once this is complete, you should see the content of each slide with the correct background image behind it.

Finally, add a frame to the end of your movie. Place some static text on that frame that says something like "End of slideshow, click to exit."

Alright, now it's time to move on to some ActionScript. Create a new layer for your actions. There are a few statements you'll need to include right away. First, you want this movie to play full screen so add an fscommand.

ActionScript Code:
  1. fscommand("fullscreen","true")-;

To make sure the Stage resizes correctly specify the scaleMode.

ActionScript Code:
  1. Stage.scaleMode = "exactFit";

Finally, you don't want the movie to begin playing through all the slides right away before the user starts clicking, so add a stop function.

ActionScript Code:
  1. stop();

You'll need to include some functions that will be used frequently to navigate the presentation.

ActionScript Code:
  1. function gotoNextSlide():Void {
  2.    if (_currentframe < _totalframes) {
  3.       gotoAndStop(_currentframe + 1);
  4.   } else {
  5.       quit();
  6.   }
  7.  
  8. }
  9.  
  10. function gotoPreviousSlide():Void {
  11.   gotoAndStop(_currentframe - 1);
  12.  
  13. }
  14.  
  15. function gotoHome():Void {
  16.   gotoAndStop(1);
  17.  
  18. }
  19.  
  20. function gotoEnd():Void {
  21.   if (_currentframe < _totalframes) {
  22.    gotoAndStop(_totalframes - 1);
  23.  }
  24.  
  25. }
  26.  
  27. function quit():Void {
  28.  fscommand("quit");
  29.  
  30. }

Next, we need to handle all the keyboard and mouse events so that the user can navigate through the slides. We'll do this by creating a new listener object.

ActionScript Code:
  1. var myListener:Object = new Object();
  2.  
  3. myListener.onKeyDown = myOnKeyDown;
  4. myListener.onKeyUp = myOnKeyUp;
  5. Key.addListener(myListener);
  6.  
  7. myListener.onMouseUp = myOnMouseUp;
  8. Mouse.addListener(myListener);-Here are the listener functions.
  9.  
  10. function myOnKeyDown():Void {
  11.   if (Key.isDown(Key.DOWN) || Key.isDown(Key.PGDN)) {
  12.    gotoNextSlide();
  13.   } else if (Key.isDown(Key.UP) || Key.isDown(Key.PGUP)) {
  14.    gotoPreviousSlide();
  15.   } else if (Key.isDown(Key.END)) {
  16.      gotoEnd();
  17.   } else if (Key.isDown(Key.HOME)) {
  18.      gotoHome();
  19.   }
  20.  
  21. }
  22.  
  23. function myOnKeyUp():Void {
  24.   if (Key.getCode() == 27) {
  25.      quit();
  26.   }
  27.  
  28. }
  29.  
  30. function myOnMouseUp():Void {
  31.   gotoNextSlide();
  32.  
  33. }

If the steps below is too complicated to you, you can try some PowerPoint to Flash converters. Some free office applications like OpenOffice (http://www.openoffice.org) offers the output as SWF file, but without animations and effects. Also you can try commercial converters such as Wondershare PPT2Flash (http://www.sameshow.com/powerpoint-to-flash.html) to output originals with animatinos. After all, these conversion tools can help you convert PowerPoint to Flash automatically without too much coding.

Last edited by UnrealEd; 01-08-08 at 06:34 AM. Reason: please use the [highlight=ActionScript] wrapper when posting ActionScript code
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
does dynamic flash image display consume bandwidth? janicefernandes Flash & ActionScript 1 12-29-07 09:38 AM
CamDate - Adult, Dating & Community Orientated Flash Audio / Video Chat Software CamDate.Biz General Advertisements 1 09-17-07 10:21 AM
Flash 8 to Flash 2004 MX? 12345421 Flash & ActionScript 2 04-06-07 12:29 AM
Flash Programmer wanted - Romania valheru Job Offers & Assistance 1 07-13-06 10:04 AM
Php with flash or without tables ? EraseR PHP 0 06-26-04 08:36 AM


All times are GMT -5. The time now is 10:08 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.