I\'m using MongoDB via the official C# driver with an ASP.NET MVC web site.
I have the following C# model:
public class Contact
{
public ObjectId Id
I realize that I am very late to this party but I'll post an answer anyway in case somebody else comes along looking for a solution (as I did).
The trick is to let the Mongo db driver do the deserialization:
var collection = database.GetCollection("collection name");
var contact = collection.Find(Query.EQ("Name", "Joe Blow"));
Now contact
will have the expected values.