The code from my SweNug presentation about what OWIN is, and why it matters…

Most of you can ignore this post completely! But if you attended SweNug today (September 10th), you know that I promised to publish my code. So here it is!

Code: SweNug.Owin.zip (2.30 mb)

I’m sorry for the ridiculous size of the download, but all the solutions have NuGet package restore enabled, which places an exe to restore NuGet packages in the project. This exe is quite sizable, so the download gets a bit large. On the other hand, including all the NuGet packages would make it even larger…

If you have any questions, don’t hesitate to drop me a line!

Cookie problems when using federated security and SignalR

I recently ran into a problem where the application I was working on didn’t pass the security information as expected to the server. The application in this case is a Silverlight client, with a WebAPI and SignalR backend. For security, we are using WIF…or federated security…I don’t know what to call it anymore. We aren’t really federating it today, but it is based on the same framework…

It has been a while since I was involved in the system, but I got roped back in to solve some issues. And while doing so, I discovered that I wouldn’t get a proper security context for calls made from the client to the server using SignalR. For some reason, those calls where just not being authenticated properly…

More...

The code from my SweNug presentation in Linköping

Here is the code from the demos I did yesterday at the SweNug meeting in Linköping. Or at least the pre-made code that I didn’t invent while talking…which I hope wasn’t too much…

Code: Xaml.Demos.zip (69.20 kb)

Anyhow, download it and walk through it, and ask any questions that might pop-up.

The video will be available later on when Pierre has figured out a way to get it “produced”…

Cheers!

Software Passion Summit – Smooth Streaming

Today I got to do my smooth streaming presentation here at Software Passion Summit. It is a presentation I personally love to present, but apparently there aren’t a lot of people who are interested in the topic…at least not here. The room wasn’t really full, but for those who were there, I promised to put a little code on my blog for download. So here it is: MyMediaPlayer.zip (21.93 kb).

If there are any questions don’t hesitate to contact me. Unfortunately the setup for the Microsoft Media Platform Video Editor is a bit complicated, so I can’t just zip it up and give it to you. But if you are really keen to have that as well, and find the information about it a little confusing, let me know and I will help out. I might even do a blog post about it as well…

As for the excellent tool I used for looking at my Azure storage, it is called Cloud Storage Studio, and is HIGHLY recommended. I wouldn’t consider working with Azure storage without it.

Building a template selector in Silverlight

There are several “missing” features in Silverlight that people keep bringing up, or keep trying to find solutions for. One of them is the template selector, or DataTemplateSelector class to be more specific.

The DataTemplateSelector has a single responsibility, which is the way it should be. It is responsible for returning a DataTemplate based an object. Generally, it is used in lists, where the data template can be selected based on the bound item, and thus give different templates to different kind of objects in the list.

In Silverlight, this is not possible out of the box, and instead requires us to create multiple UI controls, and hide and show them using data binding. This approach works, but it easily becomes heavy and complicated, which is why I want a template selector that works…

More...

flickrVIEWR – A flickr viewer in Silverlight – Part 3

I guess it is time to tie it all together and get the UI up and running for the flickrVIEWR. As you will notice, having built the viewmodels, the code for the UI is actually very simple. And the cool part is that there is no code in code behind at all.

But before I start creating the Xaml for the application, I’m going to hook up the viewmodel to the page and do a few little bits and pieces needed to get it all working.

More...

flickrVIEWR – A flickr viewer in Silverlight – Part 2

Hello again! It is time to go through the next phase in the development of the flickrVIEWR that I started a couple of days ago. The viewmodels. As usual I do build my Silverlight application using the MVVM pattern. I like this pattern a lot. Coming from an ASP.NET background, I think it offers a lot of nice features that I whish where available in general web development. I guess you do get some of the benefits and features by using MVC, but I have yet to try out doing that. And I will, I promise.

Anyhow…the viewmodels for the flickrVIEWR is not that complicated. Not at all. THhey have some small tricks up their sleeves, but nothing really cool. But before we get to the viewmodels I’m going to take a small detour via a service locator…

More...

flickrVIEWR – A flickr viewer in Silverlight – Part 1

I’m back! I’ve had my work up to my eyeballs the last couple of weeks. Apparently moving to the other side of the world and starting a new job takes a lot of time. So after that excuse, it is time to get started with my new project.

My fiancée has this blog where she blogs about our new life in NZ. And this is interesting to you because…? Well, it isn’t, but it is the reason for this blog post as well as a few more coming soon. On her blog, she posts pictures. These pictures are taken by her or me by a camera with several megapixels. That makes them too big for her blog. So she has to resize them before uploading them. This takes time and is annoying. So I offered to solve it in a somewhat more modern way. By using flickr. So she will upload her images to flickr and then use a little Silverlight application to show them on her blog. So that’s where this blog post is about…the flickrVIEWR…

More...