Feeds

Build a Silverlight media player

Going for gold

Application security programs and practises

Hands on Microsoft's deal with US media giant NBC Universal to stream this summer's Olympic Games online using Silverlight represents a major demonstration of the potential of Microsoft's emerging browser-based runtime and streaming service.

In keeping with the news, and following on from my earlier introduction to Silverlight, I wanted to go one step further in building a Silverlight rich-media application and service. Here, I plan to show a more realistic application that demonstrates how designers and developers can work together using Silverlight.

Let's assume you work for a media company that has just signed a new artist. You're working with designers and marketing people to come up with new ways of promoting bands online. How can Silverlight help with this?

Design

Rather than work with Adobe's Photoshop, let's encourage the designer to use the new Microsoft Expression. All the Expression tools are available on a trial basis from the Microsoft Expression web site.

First we can preview and select from the available photos and artwork using Expression Media.

Silverlight images and artwork

Browse and select artwork in Expression Blend

Expression Design can be used to build any additional graphic assets. If we need to edit the audio, change its format or crop it, we can use Expression Encoder. To create the application, we'll use Expression Blend 2 December Preview and choose File > New > Create a new Silverlight 1.0 Site project. The new site includes a holding page, some XAML, JavaScript and the all-important Silverlight.js file.

Now we can add all the images that we want to use, along with the audio file (in WMA format) to the project. Images and media can be dragged onto the design surface and arranged to create the design.

Silverlight combined cover and images

Combined images and cover in Expression Blend

The basic design is nearly done, but we need to name the buttons playButton, stopButton and pauseButton to allow the developer to attach functionality.

Develop

Now, open the site from Visual Studio - I'm using Visual Studio 2008, but Visual Studio 2005 works as well - Just select File > Open Web Site.

The smart choice: opportunity from uncertainty

Next page: Refine the design

More from The Register

next story
HIDDEN packet sniffer spy tech in MILLIONS of iPhones, iPads – expert
Don't panic though – Apple's backdoor is not wide open to all, guru tells us
Do YOU work at Microsoft? Um. Are you SURE about that?
Nokia and marketing types first to get the bullet, says report
Microsoft takes on Chromebook with low-cost Windows laptops
Redmond's chief salesman: We're taking 'hard' decisions
Cheer up, Nokia fans. It can start making mobes again in 18 months
The real winner of the Nokia sale is *drumroll* ... Nokia
EU dons gloves, pokes Google's deals with Android mobe makers
El Reg cops a squint at investigatory letters
Chrome browser has been DRAINING PC batteries for YEARS
Google is only now fixing ancient, energy-sapping bug
Big Blue Apple: IBM to sell iPads, iPhones to enterprises
iOS/2 gear loaded with apps for big biz ... uh oh BlackBerry
prev story

Whitepapers

Reducing security risks from open source software
Follow a few strategies and your organization can gain the full benefits of open source and the cloud without compromising the security of your applications.
Consolidation: The Foundation for IT Business Transformation
In this whitepaper learn how effective consolidation of IT and business resources can enable multiple, meaningful business benefits.
Application security programs and practises
Follow a few strategies and your organization can gain the full benefits of open source and the cloud without compromising the security of your applications.
Boost IT visibility and business value
How building a great service catalog relieves pressure points and demonstrates the value of IT service management.
Consolidation: the foundation for IT and business transformation
In this whitepaper learn how effective consolidation of IT and business resources can enable multiple, meaningful business benefits.