views:

1010

answers:

1

I've been playing around with creating an application using the S#arp Architecture.

One thing that is bugging me a bit is that I don't have access to any of the ASP.Net MVC item templates from the "Add New Item..." dialog. In other words I can't, for example, create a new "MVC ViewPage" or "MVC Controller" directly from the "Add New Item..." dialog.

As a result I have to create standard ASP.Net items, then manipulate the markup and code-behind to setup the correct inheritance structure.

Is there any way to get the ASP.Net MVC item templates to work within the "Add New Item..." dialog of a project based on the S#arp Architecture project template?

A: 

I found the answer thanks to the comment from Todd Smith in the original question.

The ASP.Net MVC item templates should be available in the "Add New Item..." dialog, under Web -> MVC.

What I neglected to mention in my original question (because I didn't think it was relevant) was that I had converted the original S#arp Architecture project template to VB.Net (being a bit more comfortable working in VB.Net these days). Turns out I lost the ability to access ASP.Net MVC templates during my conversion.

The fix was simple. My VB.Net version of the SharpArch.Web project wasn't identified as an MVC project. I simply had to add the appropriate project type GUID (i.e. {603c0e0b-db56-11dc-be95-000d561079b0}) to the *.vbproj file:

<ProjectTypeGuids>{603c0e0b-db56-11dc-be95-000d561079b0};{349c5851-65df-11da-9384-00065b846f21};{F184B08F-C81C-45F6-A57F-5ABD9991F28F}</ProjectTypeGuids>

Thanks Todd!

chyne
This didn't work for me, but this did -> http://stackoverflow.com/questions/1531120/asp-net-mvc-project-not-supported-by-this-installation.That first GUID always causes a cannot open this type of project error on load.
Kurt Johnson