C# Refining My Data Bucket Class Last year I wrote a post showing you how to combine the Unit of Work pattern and the repository pattern into one elegant class that I call the DataBucket. In that post the
C# Extending our JsonModel to help with model binding. In a previous post I talked about creating a JsonModel object to help when returning JsonResult from an action method. This is especially useful when you need to return the same data from
REST Making JsonResult easier with "JSON Model Objects" Lately I've been working with a client-side control library known as KendoUI. KendoUI contains a grid control that ties seamlessly to a Kendo DataSource object. The nice thing about the DataSource object is
SignalR Cannot have many tabs open with SignalR I've been quite fond of a library known as SignalR. The library wraps several different communication protocols: Websockets, server-sent-events, and long-polling. You don't really need to know exactly what those are. Just know
C# Getting Your Database Back in Sync With Your Entity Framework Code First Model I've been playing with Entity Framework 5 and Code First for the past few days. At some point during development of a new application I needed to update my model but could no
Visual Studio Visual Studio Express 2012 Okay, I'm hooked. The 2012 express line of Visual Studio products is amazing. I am actively working on several hobby projects and I had decided to stick with the Visual Studio Express for
C# How to combine the Unit Of Work pattern and Repository pattern in an easy and intuitive way How to structure my data layer in a project is something I have put a lot of thought into. It would seem that I'm a little OCD when it comes to code cleanliness
C# How To Properly Return A Paged Result Set From Your Repository If you follow this blog then you know that I discourage the practice of returning IQueryable<T> from your repositories. A common criticism I receive about my use of "verbose repositories"
C# Should you return IQueryable<T> from Your Repositories? The internet has been abuzz for a long time with fierce debates about whether or not you should return IQueryable<T> types from your repositories. I do have a fairly strong
C# SignalR is Amazing! I have to share a library with you. It's just so awesome that it can't stay contained. It's called SignalR. For a couple years I've been searching for a simple workable .NET solution
C# I am done using the repository pattern in 90% of my projects. Recently I've found myself starting a bunch of smaller websites for family members and friends. When I start these projects I dive head-first into a solid pattern of development that will extend long-term
C# What is the difference between "(type)object" and "object as type"? object myObject = "Hello World."; string myString = myObject as string; object myObject = "Hello World."; string myString = (string)myObject; I constantly forget the difference between these two usages of type conversion so I decided to
.NET Missing System.Web in Console Application I have been working on a project which involved building a class library and then consuming that class library in a console application. Pretty standard stuff. The problem was, when I added a
.NET How to Prevent ASP.NET MVC Action Method Ambiguity It is sometimes easy to run into action method ambiguity when you have two action methods with the same name (e.g. one for POST and one for GET), like this: [HttpGet] public
.NET ASP.NET MVC TryUpdateModel vs UpdateModel I have answered this question a few times now so I figured I'd throw up a quick post about it; hopefully Google will catch it when future people inquire. If you are used
.NET ASP.NET MVC Model Binding Security Model binding is the concept of taking values passed in through a browser request and binding them to C# objects/variables. If you're familiar with MVC then the following action method should look
C# What is a mocking framework? Why is it useful? Today I want to talk about mocking frameworks and why they are useful. In order to do that I first need to propose a scenario to you in which we will be testing
.NET Understanding the Var Keyword At work we've been putting together a coding standards document so that everyone adheres to similar code usage. This keeps everyone on the same page and makes it easy for another programmer to
Entity Framework Introduction to Entity Framework: Part IV - IQueryable This is part four of my Entity Framework tutorial. If you have not read the previous parts of this tutorial and you do not know how to setup EF and write LINQ queries
Entity Framework Introduction to Entity Framework: Part III - Building the Model This is part three of my tutorial series on Entity Framework. If you have not read parts one or two and do not have a good understanding of what an Object Relational Mapper
Entity Framework Introduction to Entity Framework: Part II - Designing the Database This is part two of my tutorial series on Entity Framework. If you have not read part one and do not have a good understanding of what an Object Relational Mapper (ORM) is,
Entity Framework Introduction to Entity Framework: Part I - Object Relational Mapping Table of ContentsPart II - Designing the DatabasePart III - Building the ModelPart IV - IQueryableNow that I've completed my Introduction to LINQ tutorial I want to move on to another technology that
C# Introduction to LINQ: Part IV - Putting it All Together This is part four of my introduction to LINQ tutorial. If you have not read the previous parts in this series and you do not have a decent understanding of delegates, lambdas, and
C# Introduction to LINQ: Part III - Extension Methods This is part three of my introduction to LINQ tutorial. If you have not read parts one and two and you do not have a decent understanding of delegates and/or lambda expressions,
C# Introduction to LINQ: Part II - Lambda Expressions This is part two of my introduction to LINQ tutorial. If you have not read part one and do not have a decent understanding of delegates in C# then please head over and