Resharper 5 and Asp.Net MVC

Just discovered this now. When you add a new action to an ASP.Net MVC controller, Resharper 5 marks the View() method as “in error”:

Error!

At first, I was a bit confused. I mean, the code was that simple, it was not possible that it should contain errors. But then I hovered over the “erroneous” method, and lo and behold:

1-Resharper

There’s nothing wrong with the C# code, but it’s the actual view (the .aspx file) that’s missing. And I even have to option to create one. So, let’s try that:

2-Popup

I get a nice popup asking for some extra params. No need for them, so we just hit enter to dismiss the dialog. And yes, Resharper creates the view for me, at the correct location:

3-ViewCreated

Easy as pie, but it’s a nice touch *and* a timesaver. But that’s what Resharper is for, isn’t it?


About this entry