Azure 1.3, Rewrite module and a 'Faulted' System.ServiceModel.Channels.ServiceChannel

I recently updated to Azure SDK 1.3. Then I tried to debug my solution locally. This is where the trouble began. The problem was that I was using the IIS Rewrite module without having it installed. Rewrite was part of Azure SDK 1.2, but it has to be installed separately for 1.3. I guess I should have read the release notes. Here is what the problem was, and how I found the solution. I would consistently get Read post »

Entity Framework 4 many-to-many

I had another problem with EF4 today. Code that worked fine in .NET 3.5 didn’t work after I regenerated the entity model using Visual Studio 2010. I found an answer, again on Stack Overflow: http://stackoverflow.com/questions/2243618/how-do-you-insert-or-update-many-to-many-tables-in-net-entity-framework It turns out that the generator decided that one of my foreign keys in an associative table should have a StoredGeneratorPattern of Identity, meaning it thought it was an identity column. When it isn’t. But updating the Read post »

1..0 or 1 relationships in Entity Framework

I came across this problem today when migrating a project from VS 2008/.NET 3.5 to VS 2010 RC1/.NET 4.0. I don’t actually think it’s a VS 2010 thing, though. I have two entities A and B. There is a navigation property on A, and it can have either one or no instances of B. B’s foreign key is to A’s primary key (obviously) but B also has its own primary key. In Read post »

AJAX history with ASP.NET AJAX 1.0

If you are still using the original ASP.NET AJAX 1.0 release, you may be looking for a way to use .NET 3.5 SP1′s “history” feature of the ScriptManager control. A while back, Nikhil Kothari wrote a component called UpdateHistory, which looks like what was integrated into 3.5 SP1. It certainly solved my problem. Combine it with HttpUtility.ParseQueryString and you’re onto a winner! Read post »

Entity Framework: Part 2

I have been reading a bit of the documentation about the ADO.NET Entity Framework. There are a few passages that relate to my previous post: Because referenced objects are not automatically loaded, you must call the Load method on the entity reference to load the related object data into the object context. You can also specify a query path that defines which related objects to load with returned objects. For more information, see Querying Data as Objects (Entity Framework) Read post »