Posts

Showing posts from January 5, 2012

Building application using ASP.NET MVC and MongoDB

Image
This article talks about building a simple application using ASP.NET MVC and MongoDB. From my earlier blog post, the installation steps for Mongo DB were explained. For building application using MongoDB and .NET, we need the 10gen C# Driver. This can be downloaded from http://github.com/mongodb/mongo-csharp-driver/downloads Let’s began creating a simple ASP.NET MVC 3 application. We will be creating a simple application which will save the contact details and view the same. The contact model is as show below     public class Contact     {         [ Required ]         [ Display (Name = "Contact ID" )]         public int ContactID { get ; set ; }              [ Required ]         [ Display (Name = "Name" )]         public string Name { get ; set ; }         [ Required ]         [ Display (Name = "Contact Number" )]         public string ContactNumber { get ; set ; }         [ Required ]         [ Displa