Browse by Tags

All Tags » ASP.NET MVC (RSS)

Using Autofac DynamicProxy2 Interceptors with MVC3–Part 2 by nmarun

Continuing from the previous post , the interceptor is now ready to be registered and consumed. In the Application_Start() method of my Global.asax.cs, I create an instance of the IoC container and register all the types. 1: protected void Application_Start...

Using Autofac DynamicProxy2 Interceptors with MVC3–Part 1 by nmarun

Autofac is an IoC container and using DynamicProxy we can intercept method calls to perform custom logic. What this means is that, you can actually add ‘hooks’ to methods in your code so that when these methods are called, you automatically invoke an...

Some cool features introduced in ReSharper 6 by nmarun

I recently upgraded to ReSharper 6 and the experience so far has only been positive. Here are the top things for which I said ‘Good job Jetbrains ’. View Completion – So now you will be able to get intellisense on Views as well. Say you’re in your razor...
Filed under: , , , ,

WCF Data Services Toolkit to talk to any database using GetAll, GetOne, Save, Remove methods by nmarun

I did a primer on using WCF Data Services in my last post . One of the things I’m seeing about the posts regarding WCF Data Services using OData is that they used Entity Framework to do the DAL work. So a lot of underlying work gets hidden by using EF...

Attach to IISExpress process from Visual Studio by nmarun

With VS2010 SP1, you can attach an application process to IISExpress to enable debugging of an application. Here’s how: I have an MVC application with the following setup. 1: public class HomeController : Controller 2: { 3: public ActionResult Index(...

Executing SQL queries on SQL CE 4 through Entity Framework by nmarun

In my previous blog , I wrote about how to use inheritance through entity framework on SQL CE database. In this blog however, I’ll explore how you can run a typical SQL query statement on the database table and read/write the values. I will build on the...

Entity Framework Model Inheritance with SQL CE 4 by nmarun

For some (unknown) reason, I’ve been curious to work with SQL CE, just hadn’t gotten a chance to work with it. If you’re not familiar with what SQL CE is all about, go through this article from Scott Gu . To begin with I have an empty MVC 3 application...

HTML5-MVC application using VS2010 SP1 by nmarun

This is my first attempt at creating HTML5 pages. VS 2010 allows working with HTML5 now (you just need to make a small change after installing SP1 ). So my Razor view is now a HTML5 page. I call this application - 5Commerce – (an over-simplified) HTML5...

Templated Razor Delegates – Phil Haack by nmarun

This post is largely based off of Phil Haack ’s article titled Templated Razor Delegates . I strongly recommend reading this article first. Here’s a sample code for the same, so you can have a look at. I also have a custom type being rendered as a table...
Filed under: , , ,

ASP.NET MVC ‘Extendable-hooks’ – ControllerActionInvoker class by nmarun

There’s a class ControllerActionInvoker in ASP.NET MVC. This can be used as one of an hook-points to allow customization of your application. Watching Brad Wilsons’ Advanced MP3 from MVC Conf inspired me to write about this class. What MSDN says: “Represents...
Filed under: , ,
More Posts Next page »