Expression Blend, Silverlight

What’s new in Expression Blend for visual studio?

Intro With the release of Windows 8 Customer Preview came the release Visual Studio 11 Beta. This beta release van with a new version of Expression Blend. To get it, just download the Visual Studio 11 Beta and install the Ultimate, Premium of Professional version. If you don’t have installed or don’t want to install Windows 8, you can install Visual Studio on Windows 7 now. It runs side by side with any previous installation of that. There is one downside of running the Beta on Windows 7: you can’t develop WinRT applications. The file->new Project windows is even completely…

Expression Blend, Silverlight, Visual Studio

Customizing Silverlight properties for Visual Designers

When building custom or user controls you probably end up with a large amount of properties on that control. When using the control in a visual designer like Blend or the Visual Studio designer these properties just show up. Adding a bit of structure in this can be done very easily by adding a couple of attributes to the properties. The attributes to let the visual design know what to do can be found in the System.ComponentModel namespace. There’s a WPF version of this namespace also. For the sake of simplicity I’ve created a UserControl and set the background color…

Silverlight

Dependency Injection, MVVM, Ninject and Silverlight

Intro The MVVM patterns is pretty popular these days. In Silverlight and WPF it is used a lot. Dependency Injection is also used very often. In this tutorials I would like to show you how to use Dependency Injection when building a Silverlight application using the MVVM pattern. There are numerous Dependency Injection Frameworks. For this tutorial I’ve chosen Ninject. The main idea on how to implement DI in your application is pretty much the same for all frameworks. In this tutorial I hope I can give you a small introduction in using Ninject in you projects. Ninject is an…

Presentation, Silverlight, Slides

Unit testing MVVM in Silverlight – SDN Event–Code and Slides

Yesterday I gave a talk at the SDN Event in Zeist about Unit testing MVVM in Silverlight. I talked briefly about how MVVM works in Silverlight and dove deeper into the Unit Testing Framework which is available in the Silverlight Toolkit. After going through the various attributes used in the framework I gave a demonstration on how to use StatLight, a command line tool for running tests. I would like to thank anyone who attended my session for coming and SDN for organizing and hosting this great and informative day. Slides Code  

.NET, Silverlight, Visual Studio

NuGet

If you often use open source libraries you probably have a large library with various tools, like I do. NuGet is an extension for visual studio that enables you to install, uninstall and upgrade open source packages into your application very easily. Say for example you want to use MvvmLight or Ninject in your project, with NuGet it’s nothing more that tell it to add the package to your project. NuGet NuGet (formerly known as NuPack) is a free, open source developer focused package management system for the .NET platform. You can download the .vsix extension at http://nuget.codeplex.com. After installing…

Expression Blend, Silverlight

Using Visual States in custom controls in Silverlight

Intro Visual States are an easy way to change the looks of your controls based on certain states. This state can be something like a mouse hover, some invalid state or any state you need in a control. For this tutorial I chose a traffic light control that can be one of four states. Green, Orange, Red and Inconclusive (blinking orange). In the end I show you how to use behaviors on buttons to set the state of the traffic light. This makes the use of visual states perfectly suitable for use in MVVM projects. Part 1 – Setting up…

PivotViewer, SilverBullet

PivotViewer and MVVM

PivotViewer series Building your first PivotViewer application Runtime PivotViewer collection creation PivotViewer – Working with Facets Handling PivotViewer events PivotViewer – Custom actions PivotViewer and MVVM Intro The MVVM patterns is a commonly used pattern in Silverlight. Because of databinding MVVM suits perfectly for WPF and Silverlight. But use it only if appropriate. Often the pattern is used when it isn’t necessary. The usage of any pattern should be a helping tool, not an enforced law. Having that of my chest, lets look at the Silverlight PivotViewer control in combination with the MVVM pattern. To make a long story short,…

PivotViewer, Silverlight

PivotViewer – Custom Actions

PivotViewer series Building your first PivotViewer application Runtime PivotViewer collection creation PivotViewer – Working with Facets Handling PivotViewer events PivotViewer – Custom actions PivotViewer and MVVM Intro In this tutorial about the Silverlight PivotViewer control I would like to explain how to make use of Custom Actions. Small labels are placed on top of items in the viewer and clicking them will trigger an event. They look something like this: The only downside of these actions is that they aren’t fully implemented. So you’ll have to extend the PivotViewer control yourself. If you haven’t worked with the PivotViewer before, you…

PivotViewer, Silverlight

Handling PivotViewer events

PivotViewer series Building your first PivotViewer application Runtime PivotViewer collection creation PivotViewer – Working with Facets Handling PivotViewer events PivotViewer – Custom actions PivotViewer and MVVM Intro Today I would like to go into a little detail about the events used in the PivotViewer control for Silverlight. If you haven’t worked with the PivotViewer yet you might want to read the getting started tutorial I wrote earlier first. CollectionLoadingCompleted The CollectionLoadingCompleted event is fired when loading of the collection is completed. CollectionLoadingFailed The CollectionLoadingFailed event is raised when an error occurs when loading a collection. The event uses gets an…

PivotViewer, Silverlight

PivotViewer – Working with Facets

PivotViewer series Building your first PivotViewer application Runtime PivotViewer collection creation PivotViewer – Working with Facets Handling PivotViewer events PivotViewer – Custom actions PivotViewer and MVVM Intro In this next tutorial about the Silverlight PivotViewer control I would like to give a little more depth on Facets. What are facets, and how are they used in runtime generation of collections using the PivotServerTools library. This tutorial continues on techniques from last tutorial about runtime collection creation. If you are just getting started using the PivotViewer control, you might want to have a look at the Getting Started Tutorial first. This…