March, 2008

  • DaveDev

    Creating Amazing User Experiences on the Microsoft Platform - available for download now!


    As previously mentioned here I will be posting all my material from the Financial Developers Conference session online. 


    You can now grab the Powerpoint here.

    Grab the Source Code here.

    Here is a breakdown of what you will find in the zip file.


    • This is the project where I showed how easy it was to add Ajax too an existing ASP.NET Website using VS2008.
    • Two pieces of code to to watch for here.  First is the UpdateProgress control, this is what enabled us to throw up a message when we simulated server traffic.  To simulate server traffic just put the thread to sleep for a few seconds.  I did this in the Button click event but you can do it anywhere really.
          <asp:UpdateProgress ID="UpdateProgress1" runat="server">
                  Loading, Please Wait...
           protected void Button1_Click(object sender, EventArgs e)


    • This project showed a sample of creating a new Silverlight 2.0 application using the templates in VS2008.  We covered how to create a mirror shadow on an image (to make it look like glass) a simple storyboard animation and then how to add video as a brush to an element.  This is something that is very easy to do in XAML and has some great effects.  You'll see in the code we create a MediaElement for the video and then just apply it as a Video Brush on the text foreground.  You could do this for any element really, even your buttons or listboxes. =)
        <MediaElement Height="152" HorizontalAlignment="Right" Margin="0,0,25,28"     VerticalAlignment="Bottom" Width="178" x:Name="myVid" Source="Bear.wmv" Visibility="Visible" Opacity="0"/>
        <TextBlock Height="59" HorizontalAlignment="Left" Margin="45,0,0,52" x:Name="myText" VerticalAlignment="Bottom" Width="203" 
    Text="USING VIDEO" TextWrapping="Wrap" FontSize="24" > <TextBlock.Foreground> <VideoBrush SourceName="myVid"/> </TextBlock.Foreground> </TextBlock>


    • This project showed how we can easily use timers now in our code behind in Silvelright 2.0.  The old days of using a Storyboard to keep track of time and fire off events are slowing fading.  Thanks to Tim Sneath for the idea from his excellent hands on lab.  Basically we create a new Dispatch Timer and every time it fires off its Tick event we change the color of the button text.
                timer= new DispatcherTimer();
                timer.Interval = new TimeSpan(0, 0, 2);
                rng = new Random();
                timer.Tick += new EventHandler(timer_Tick);
            void timer_Tick(object sender, EventArgs e)
                Byte[] colors=new byte[3];
                btnClick.Foreground=new SolidColorBrush(Color.FromArgb(255,colors[0],colors[1],colors[2]));


    • This project is the DeepZoom project.  I did not include the image output from DeepZoom Composer due to size constraints as well as the Heores mp3 file due to copyright.  I will be posting a screencast very shortly that will take you step by step how to build your own.  The Deep Zoom image itself is just a MultiScaleImage element declared in the XAML.  The mp3 I played was a declared as a MediaElement and then I just added an event handler to capture keyboard input off the control itself.  I used W for play, S for pause and X for stop.  The actual handling of the mouse to Zoom and Pan was done via the "Nerd Silverlight" code snippets the amazing guys at IdentityMine posted here.  Other than that I just formatted the control itself to be a little bit smaller than 1024x768 so when I went into full screen IE mode the illusion all played out nicely so it looked like a Powerpoint.
           <Grid x:Name="LayoutRoot" Background="White">
            <MultiScaleImage x:Name="myZoom" Width="1014" Height="766" 
    Source="http://localhost:49862/TestDepth_Web/ClientBin/FinServHeroes/info.bin" Cursor="Hand"
    MouseLeftButtonDown="myZoom_MouseLeftButtonDown" MouseLeftButtonUp="myZoom_MouseLeftButtonUp" MouseMove="myZoom_MouseMove" /> <MediaElement x:Name="mp3Heroes" Source="http://localhost:49862/TestDepth_Web/ClientBin/Heroes.mp3" AutoPlay="False" /> </Grid>
            public Page()
                this.KeyDown += new KeyEventHandler(Page_KeyDown);
                myZoom.KeyDown += new KeyEventHandler(myZoom_KeyDown);
            void Page_KeyDown(object sender, KeyEventArgs e)
            void CheckMusic(KeyEventArgs e)
                switch (e.Key)
                    case Key.W:
                    case Key.S:
                    case Key.X:


    • This was the sample AJAX project we did where we applied a Shadow Extender to the button and some CSS. 


    • This is the project where I showed how to add video to an existing ASP.NET Web Application using the new Silverlight AJAX controls.  We also went in and modified the XAML for the player skin and added a DevCon logo animation that fired off when the Canvas was loaded.  This showed how easy it is to fire off events in XAML directly using Triggers and the ability to create rich animation using Expression Blend.  Thanks to Brad Abrams for the original idea and inspiration behind this.  Brad also did a really awesome session at Boston Remix on using Video in your Web Applications.  Check it out here.
    <Storyboard x:Name="myLogoSpin"/>
            <EventTrigger RoutedEvent="Canvas.Loaded">
                    <Storyboard x:Name="spinMyImg">
                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="image" 
    Storyboard.TargetProperty="(UIElement.Opacity)"> <SplineDoubleKeyFrame KeyTime="00:00:02" Value="1"/> <SplineDoubleKeyFrame KeyTime="00:00:04" Value="1"/> <SplineDoubleKeyFrame KeyTime="00:00:05" Value="0"/> </DoubleAnimationUsingKeyFrames> <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="image"
    Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[2].(RotateTransform.Angle)"> <SplineDoubleKeyFrame KeyTime="00:00:02" Value="0"/> <SplineDoubleKeyFrame KeyTime="00:00:04" Value="361.077"/> </DoubleAnimationUsingKeyFrames> </Storyboard> </BeginStoryboard> </EventTrigger> </Canvas.Triggers>


    • This project was originally part of Kevin Moore's WPF Bag-O-Tricks.  What I did for the session was just create a new Blend Project and import most of the XAML.  The great thing about this demo is it shows a really slick animation based on mouse movement without any code behind.  It is done entirely in XAML using triggers.  Check it out!

    Feel free to email me with any questions.  I plan to have the Deep Zoom and Video Editing screencasts done shortly and will post the links up here so stay tuned.

  • DaveDev

    New Devs4Devs Video - A Step By Step Guide to Silverlight DeepZoom


    It's out, go grab it!


    Technorati Tags:
  • DaveDev

    Local to the NY/NJ/PA/CT/MA area and want a hands on demonstration of Microsoft Surface? How about some amazing free OBA, Silverlight, WPF, SharePoint and .Net content?


    Then come on down to Atlantic City, NJ for the annual Health and Life Sciences Developers Conference April 22-24th!


    Registration is free, but space is limited.  Based on feedback from last year, the conference is actually broken up into two half days and one full day.  So you can come on down and play some poker before hitting the sessions later in the day. 

    Not only that, the conference is connected right to the AC Convention center.  This means you can take a train from any of the major cities or airports directly into the conference. 


    There is a great agenda lined up for you.  Check it out here.

    Some of the sessions I'm looking forward to...

    OBA Reference Toolkit for the Enterprise
    Karthik Ravindran, Principal Architect, Microsoft
    Office Business Applications (OBA) are applications built to bridge the results gap
    between personal and business productivity. These apps combine the familiarity of
    Microsoft Office clients with the power of Microsoft Office SharePoint platform to
    create roles based, collaborative solutions that extends the line of business and
    backend systems. The OBA Composition Reference Toolkit brings to surface the
    underlying composition capabilities of the 2007 Microsoft Office system. It integrates
    seamlessly with the Microsoft Office 2007 System to enable a prescriptive application
    composition experience for Information Workers to build and deploy Office Business
    Applications (OBAs) using semantically related OBA Components like Workflows,
    SharePoint document libraries and lists, SharePoint Pages, Web Parts, VSTO Office
    Client Add-ins, BI Reports, BI Dashboards etc. The toolkit comprises an OBA
    Composition Server and an OBA Composer.

    An Introduction to Programming Silverlight 2.0
    Jesse Liberty “Silverlight Geek,” Senior Program Manager, Microsoft
    This talk will cover the fundamentals of building Rich Internet Applications with
    Silverlight 2.0 and Visual Studio 2008. Topics covered will include a fast introduction
    to Silverlight, an overview of what you need to develop Silverlight applications and
    how Silverlight applications are deployed and used, and then a focus on creating
    Silverlight applications from the perspective of the software developer. Topics
    covered will include: XAML and Code behind, Controls and event handlers, Creating
    objects in XAML and in C#, Layout management, Transforms and basic Animation.

    WPF and Silverlight for Information and Data Visualization in Life Science
    Sam Batterman, Industry Solution Specialist, Microsoft
    Come see examples of how to use the new Windows Presentation Foundation and
    Silverlight to build compelling and spectacular User Experiences (UX) in Life Science.
    We will be premiering the InfoMesa application which fuses together concepts of
    Electronic Notebooks, Literature Search, and Mechanism of
    Action, while integrating SharePoint, and Unified Communication

    Biomedical Visualization using the Xbox360
    Krishna Kumar, Microsoft
    The Xbox360, as the most popular gaming console to date has achieved ubiquity not
    only in homes, but increasingly, also in the hospital setting as an entertainment hub
    for patients by providing a positive diversion, allowing them to listen to music, play
    video games and watch movies or live TV. Efforts such as ‘Cerner MyStation’ are a
    testament to this fact.

    I will be there doing a session as well so be sure to stop by and say hello!

    Creating amazing user experiences with Silverlight 2 and Expression Studio
    David Isbitski, Developer Evangelist, Microsoft
    Web applications with sound, animations, and video have become the rule and not
    the exception these days. But as a developer how do I get started in an area that
    previously meant learning entirely new tools and technologies? This session will
    get you up to speed on how to use the latest web technologies from Microsoft
    including Silverlight DeepZoom, Expression Blend, Expression Encoder and
    Silverlight Streaming that leverage your existing .NET Skills and integrate seamlessly
    with ASP.NET. You’ll be amazed at how easily you can start adding great user
    experiences to both your new and existing applications today!

    What are you waiting for?  Come join your peers and have some fun down in AC!

    Technorati Tags:
  • DaveDev

    The new technology behind Silverlight DeepZoom



    When you get a chance check out this article by Jon Galloway over at Vertigo. 

    Jon covers the new technology behind Deep Zoom and also goes into details comparing it with the Google Maps API and Flash Zoomify. Very cool!

    Technorati Tags:
Page 1 of 3 (11 items) 123