Enhanced CD Blues
Written at 1am on 07.12.06
Filed under Software / Tutorials & Resources / Apple / ALL CATEGORIES
2 comments (closed)

As we all know, even the simplest projects can turn out to be extremely complex, and this unnecessary complexity is most usually caused by one very small aspect; a miniscule but deadly fly swimming in your ointment labeled ‘Project’.
Such a scenario reared its head today whilst I was trying to create a simple Flash-based menu for an Enhanced CD. Sanctuary have a Flash projector template for ECDs that they deploy for each project with only a couple of minor adjustments (namely, the FLV file and the accompanying CD artwork that serves as a backdrop to the video player). However, this ECD (for The Cooper Temple Clause’s single ‘Waiting Game’) needed a further modification due to the inclusion of the U-MYX app: rather than auto-running (on a PC) the projector file, a new menu should be displayed: one offering the choice of launching a) U-MYX, or b) the Flash projector containing the video. Sounds simple enough, eh? I designed an icon for the video player and made the menu in Flash:
Before anything else, fscommand was used to make the projector appear fullscreen but not resize. I placed the following code on frame 1:
fscommand("fullscreen", true);
fscommand("allowscale", false);
After sorting this out, the first real problem I ran into is that using getURL actions on the buttons causes the unnecessary opening of browsers, so I called on good ol’ fscommand again to launch the applications instead:
on (release) {
fscommand ("exec", "projectorName.exe");
}
Now, that should’ve worked. And it did, when launching the Flash projector containing the music video, but not at all when attempting to launch the U-MYX app. Has anyone got any ideas why?!? According to this technote from Adobe, this technique should be able to launch any application, but it failed to launch anything besides the projectors… on both Mac and PC.
To get round the problem, someone suggested I get Flash to launch a batch file (.bat) containing a script to auto-launch the U-MYX application. Launching a text file to launch an app seemed like a long, roundabout way of doing it, but it also turned out to be the only option that worked, so I wrote ‘pcScript.bat’, which simply contained one line: U-MYX.exe
Problem solved on Windows, but what about Macs? As hinted at in the technote, AppleScript was needed. Now, I’ve never written Applescript before, and although the syntax is extremely simple, one thing that immediately had me confused was the fact that you need to open a script and then manually hit the ‘run’ button for something to actually happen. This was particularly annoying, as I’d written a script that worked at that level but had no way of getting Flash to run it automatically.
tell application "U-MYX-player" activate open file "the_cooper_temple_clause#16.umx" end tell
After some scurrying around online and in the AppleScript Help menu, I finally found the (extremely simple) solution: to save the script as an application. Ok, ok, you can stop laughing now - the reason I didn’t try this before was because I didn’t expect it to work; after all, U-MYX is an application too, right? And that just wouldn’t launch. However, for whatever reason, an AppleScript app is different to a normal one, and it worked like a charm… although I’m still stuck into this silly launching-an-application-to-launch-an-application routine.
Surely there must be another way… anyone?
2 comments (closed)
Comments are currently closed on this entry, but you can still read those that have already been posted...
Search
Speaking engagements
- Web Developers Conference 12th November 2008
- Spletne Urice, Ljubljana 29th October 2008
- SkillSwap Brighton 20th August 2008
- Future Of Web Design, London 17th & 18th April 2008
- Future Of Web Design, New York 7th November 2007
- SkillSwap Bristol 25th September 2007
- iDesign: design for life (part of the London Design Festival) 18th September 2007
- Oxford Geek Night 25th July 2007
Recent posts
- Why being freelance does not mean you have to work more hours
- Starkers for WordPress 2.6.2
- Forthcoming speaking events
- Thwart the design thieves feature in .net magazine
- Death to IE6
- Vote for my SXSW ‘09 panels
- Bypassing the new Delicious site
Categories
- ALL CATEGORIES (89)
- Apple (9)
- Carsonified (2)
- Cooking With Beer (1)
- Design inspiration (2)
- Life In The Real World (32)
- Publication & Recognition (21)
- Software (14)
- Speaking Engagements (11)
- That Internet Thing (15)
- The Business (5)
- This Site (14)
- Travel (10)
- Tutorials & Resources (10)
- Web Design (32)
- Wordpress (5)
- Writing (1)
Blogroll
UPDATED! I’ve been known to while away a few hours on these blogs, most of which are written by my friends in the industry...
- Jørgen Arnor Gårdsø Lom
- Jina Bolton
- Nathan Borror
- Mark Boulton
- Sam Brown
- Andy Budd
- Kevin Cornell
- Jeff Croft
- Jon Hicks
- I Love Typography
- Shaun Inman
- Roger Johansson
- Daniel Mall
- Kyle Meyer
- D. Keith Robinson
- Jason Santa Maria
- Dave Shea
- Jonathan Snook
- Jon Tan
- Typesites
- Tim Van Damme
- Khoi Vinh
- Web Designer Wall
- Rob Weychert
Recent Comments:
- Rajesh Pancholi said: sorry for the babbling : )
- Rajesh Pancholi said: Good for you, remember why you’re making the change and don’t...
- prisca said: Elliot, great to read you’re making such a success of your freelance life ;-)...
- Christoph said: Very motivating and encouraging article! But I have some second thoughts :-)...
- Pete Eveleigh said: BTW I loved this bit… I’m not the type of guy who’ll write a blog...
- Pete Eveleigh said: I tend to agree with what you say but the article doesn’t really say...
- Gary Stanton said: Wish I knew how you did that. I’ve been freelance for around three years...
- Phil Bowell said: Whilst your post is very encouraging, I’m in agreement with John (the...
- Dave Ellis said: I seem to be going the opposite way, I need to make a conscious decision to work...
- Alex Older said: I’m looking to make the jump after Uni depending on how things go and this...
Recent Reads
-
Basics Design: Layout (Gavin Ambrose & Paul Harris) - A beautifully designed book about beautiful design. Some key layout principles are presented in an engaging way, and this is more a book about inspiration than pure instruction.
-
Poe: Illustrated Tales of Mystery and Imagination (Edgar Allan Poe) - Some fine contemporary illustrrators take on some Poe classics and the result is a gorgeous collection of words and art.
-
Penguin By Design (Phil Baines) - A history of Penguin Books’ cover designs, as educational and inspirational as you’d expect from this prolific publisher.
-
Thinking with Type (Ellen Lupton) - I first saw this sitting on a desk in the nytimes.com offices, and after thumbing through it, realised it was one of the best books about the technicalities of typography that I’d seen.
-
Hellboy: The Troll Witch and Other Stories (Mike Mignola) - The latest Hellboy trade paperback collects yet more classic stories, although this time Mignola is joined by other artists.
-
The Ten Commandments of Typography (Paul Felton) - A book of two halves (the flip-side deals with so-called ‘Type Heresy’), this is a witty but informative book bout typographical techniques.
-
Great Beers of Belgium (Michael Jackson) - No, not that Michael Jackson. This is the one who really knows his stuff when it comes to fine beers.
-
London: The Biography (Peter Ackroyd) - A lively, engaging book about the history of London, told as it the city itself were a living thing.
-
Tres Logos (various) - I could look through logo books until the cows come home; this kind of collection is invaluable to the identity designer, and this is, of course, just one book.
-
Business Cards 2: More Ways Of Saying Hello (various) - This is another great source of inspiration and a lovely ‘coffee table’ book that’s a joy to flick through even if you don’t need to design a business card.
-
Schild’s Ladder (Greg Egan) - One of the most full-on sci-fi books I’ve ever read, with its use of real physics and exploration of quantum mechanics shaping much of the narrative.
-
Wolverine: Weapon X (Barry Winsor Smith) - A landmark story in the history of this legendary comic book character, Weapon X has become a real classic.
-
Casa Batlló: Gaudi (various) - Sam and I visited Barcelona last year, where we saw several amazing architectural feats by Gaudi. This book captures some of the beauty that our camera couldn’t.
-
The Fundamentals of Typography (Gavin Ambrose) - This was the first bok I bought specifically about typography, and it pretty much does what it says on the tin, although a nice bit of history is thrown in as well.
-
Analog In, Digital Out (Brendan Dawes) - Magnetic North’s main man explores some arty, experimental projects without any of the ponce usually associated with the genre. This is a book about merging new and old ideas, and it’s inspiring all the way through.
-
The God Delusion (Richard Dawkins) - Possibly one of the most important books in print today.
-
Foundation’s Edge (Issac Asimov) - Another Asimov classic, this part of The Foundation Saga encapsulates some monumental ideas about humanity far beyond the boundaries of regular sci-fi.
-
Web Standards Creativity (various authors) - 10 great lessons for writing better markup, using the latest CSS, and adding subtle Javascript tricks
-
Transcending CSS (Andy Clarke) - Rethink the way you design and code. This book was hugely influential on me whilst building the latest version of this site and made me even more pedantic
-
Dune (Frank Herbert) - An absolutely legendary sci-fi novel full of very complex ideas... much better than the film!
-
Neverwhere (Neil Gaiman) - A dark and charming tale of a man who eschews normal life for the secret underworld of ‘London Below’
Flickr
View all of my photos on flickr
Simon Birchall
26.07.07
#
Reason your U-mix fscommand failed is the hyphen in the fscommand filename - it isn’t allowed .. take it out & rename the exe - all should work as expected.
Elliot Jay Stocks
06.08.07
#
Wow, thanks Simon! Sadly too late to change this as the CD went out months ago (and I no longer work for Sanctuary) but that’s really useful to know about fscommand. Cheers!