Silverlight Entity Framework Astoria == Crazy?

October 19, 2007
No Comments.


I’ve been digging into the Entity Framework and Astoria and decided to create a quick little mashup of Silverlight and those two technologies.  The result is this little product viewer using the Northwind database:

The goal of the project was to use Silverlight 1.1 to design the UI, Entity Framework to design the DAL and use Astoria for the client-server communication.  I am pretty happy with the result.  I am using September previews of Entity Framework and Astoria as well as the Alpha of Silverlight 1.1 so the site may have problems from time to time as these are early releases of the products.

Astoria in particular is a very early build (and they’ve even changed the search syntax already so when the new version is released I’ll change this). The September version of Astoria comes with a Silverlight client data layer that just does not work for me currently.  But that wasn’t a problem as Astoria (for those who don’t know) is a REST-based API for access a data model. Astoria supports returning results in XML, JSON and RDP.  So all I did was use the JSON format and Silverlight 1.1’s built-in JavascriptSerialilzer to convert the results to in-memory objects.

You can download the source here:

UPDATE: Doesn’t seem to work with Firefox.  I believe this is an issue with Astoria (astoria is changing the search syntax to be more compatible with other browsers).  Might also be my resizing logic.  I’ll see if I can get it working with FF later this week.