Archive for the 'Flash' Category

How to Play Flash Video Files (FLV) Sequentially

Friday, October 19th, 2007
ActionScript 2.0 ActionScript 3.0

Half a year ago, I wrote a brief article on “How to Play Sound Files Sequentially” (AS2).  Recently, a reader was asking how to apply the same principle to video.  In his case, Paul had to play a commercial first, then follow it with a longer content video — and the user controls (buttons, scrubber, etc.) needed to be disabled wile the commercial was playing.  As it turns out, Paul worked out a solution of his own, partly based on some of the other articles here, but I thought it would be fun to do a quick version too.  That way, he can compare notes and anyone else can look on.  Keep reading »

Foundation Flash CS3 Gets a Second Print Run

Friday, October 19th, 2007
Flash General

Only three months after release, Foundation Flash CS3 for Designers has gone to the printer for a second print run.  Cool!  The publisher approached Tom and me for corrections, so the new batch should have the current handful of issues resolved.  Of course, copies from the first print are still in stores, so we’ll continue to leave up the Corrections page.  Response has been great on Amazon so far — thanks, reviewers!

How to Use Flash Video (FLV) Cue Points

Tuesday, October 9th, 2007
Flash ActionScript 2.0 ActionScript 3.0

Video cue points can be used for all sorts of things in Flash.  Typical uses involve triggering other activity, such as peripheral movie clips whose animations enhance the video content, or triggering text, such as closed captions.  I’ve seen some developers in the Adobe forums even use a cue point to signal that a video clip has reached its end.  Strictly speaking, cue points aren’t needed for that last goal (see “How to Determine the Completion of a Flash Video (FLV) File”), but it’s certainly a possible way to go.

If you’re interested in cue points yourself, but don’t know where to begin, let’s dive in.  Keep reading »

How to Retrieve FlashVars Data in ActionScript 3.0

Tuesday, September 25th, 2007
Flash ActionScript 3.0

Last year around this time, I described how to pass variables into a SWF by way of something called FlashVars.  This was discussed in “How to Tell a SWF What File(s) to Load — From the Outside” which works for pretty much any sort of simple data you may want to pass in, as long as you’re talking about relatively small groups of name/value pairs.  Complex data is more likely to be suited to XML.  In that earlier blog entry, the purpose was to re-use a single SWF numerous times to load a variety of MP3 files, by specifying which audio in the HTML.  Pretty flexible solution!  You could use the same technique for loading JPGs or FLVs, to populate dynamic text fields, or whatever you like.  The article has been fairly popular and continues to be useful — as long as your SWF is published for ActionScript 2.0 (or even 1.0 if you drop the post colon suffixes — :String, :Number, and the like).  In ActionScript 3.0, things are different.  Keep reading »

Canton Gives Foundation Flash CS3 for Designers a Thumbs Up

Friday, August 31st, 2007
Flash General

Satori Canton, of Satori Interactive and part of the ActionScript.com crew, recently wrote a wonderfully supportive review of Foundation Flash CS3 for Designers, in which he describes Tom’s and my book as “required reading for anyone considering getting into Flash development,” and a “Rosetta Stone” in guiding newcomers through the often overwhelming sense of where to begin.  This is rewarding praise from someone like Satori, who’s been playing with Flash since the early days (thanks, man!).

My aim in the Adobe forums, here on this blog, and in my other writing outlets, is to be as helpful and encouraging as I can.  I remember what it was like being new to Flash, and it always meant a lot to me when someone took the time to go into detail when replying to my questions.  I’m always pleased to hear when my own writing returns the favor.

How to Pause a Timeline (AS3)

Monday, August 27th, 2007
Flash ActionScript 3.0

If the title of this blog entry sounds familiar, it may be because you saw the ActionScript 2.0 equivalent on this site over a year ago.  In the comments to that article, a reader named Eric asked how to pause a timeline in ActionScript 3.0 (very different from AS2, as it turns out).  There’s a significant benefit to using ActionScript (whatever version) to temporarily halt the timeline, then resume after a few seconds:  it’s all about saving yourself the hassle of horizontal scrolling.  Consider pausing for five whole minutes.  At the default 12fps, that would require 3,600 frames of timeline real estate.  With code, you can pull it off in a single frame.  Let’s take a look.  Keep reading »

ActionScript:  Figuring Out Where to Begin

Friday, August 24th, 2007
Flash ActionScript 2.0 ActionScript 3.0

Here’s the third of my Notes on Design guest blog entries.  It was published yesterday already, but I missed it.  Too quick for me!

http://blog.sessions.edu/graphic-design/actionscript-figuring- out-where-to-begin/

How to Build an Interactive Flash Video (FLV) Load Progress Bar

Wednesday, August 22nd, 2007
ActionScript 2.0

A number of readers have expressed interest in the last handful of video-related blog entries.  These include “How to Build a Flash Video (FLV) Progress Bar” (Part 1 and Part 2) and, somewhat related, “How to Build a Basic Slider Widget (AS2).”  In some of the blog comments, mischa, Marius, and kweku were asking about how to display the load progress of an FLV file.  This was in addition to the existing functionality, which allows the user to see how much of the video has played and also to seek by dragging a knob along a track.  Questions included a) how to make sure the user couldn’t drag the seek knob beyond the loaded portion of the video and b) how to make the track itself clickable, so the user could bypass the knob if desired.  Let’s take a look at how to incorporate these new elements by adding them to the ActionScript 2.0 presented in Part 2 of the progress bar series.  Keep reading »

How to Save Bandwidth when Displaying Flash Video

Friday, August 17th, 2007
Flash ActionScript 2.0 ActionScript 3.0

I’m on the technical advisory board for Sessions School of Design, a distance learning school based in New York.  Anjula Duggal, managing editor for the Sessions blog (DesignSessions:  Notes on Design), recently asked me to guest author a handful of articles for them, which I’m happy to do.  Thanks to Anjula and editor Katie Feo for helping to get me squared away!  :)

My first article is here:

http://blog.sessions.edu/web-design/how-to-save-bandwidth- when-displaying-flash-video/

How to Build a Basic Toggle Button (AS2)

Tuesday, August 14th, 2007
Flash ActionScript 2.0

kweku and nab have been interested a play/pause button — essentially a toggle button, something that “remembers” when it’s been clicked — and fortunately, the mechanics are fairly simple.  The key to the desired functionality is a Boolean variable.  Let’s take a look.  Keep reading »