Removed dependency on installed ASP.NET MVC Beta

1 view
Skip to first unread message

Billy

unread,
Dec 13, 2008, 12:34:52 PM12/13/08
to S#arp Architecture
The Northwind example and Visual Studio project template no longer
depend on ASP.NET MVC Beta being installed on your development
machine. I.e., you can create and develop a project just fine without
installing the ASP.NET Beta. The drawback is that you won't have the
Microsoft-provided ASP.NET MVC item templates available. (But a
solution for even this conundrum is at
http://dylanbeattie.blogspot.com/2008/11/working-on-aspnet-mvc-beta-and-preview.html.)

The source and project template at
https://sharp-architecture.googlecode.com/svn/trunk/TemplatesAndCodeGen/VisualStudioTemplates
have been updated to reflect this change. As the hillbilly eloquently
described at http://codebetter.com/blogs/kyle.baley/archive/2008/12/12/asp-net-mvc-and-the-gaaak.aspx,
the surprisingly ridiculously simple solution was to open the .csproj
file in a text editor and remove "{603c0e0b-db56-11dc-
be95-000d561079b0};" from the list of ProjectTypeGUIDs at the top.

Billy

Kyle Baley

unread,
Dec 13, 2008, 1:02:48 PM12/13/08
to sharp-arc...@googlegroups.com
Thanks Billy. I have a related question that doesn't have anything to do with S#arp. If you remove the assemblies from the GAC, will the MVC templates still work?

Billy

unread,
Dec 13, 2008, 1:16:09 PM12/13/08
to S#arp Architecture
My (almost positive) guess is that this would not have any impact on
the availability and use of Microsoft provided ASP.NET MVC item
templates - but I have not confirmed this. ;)

Billy


On Dec 13, 11:02 am, "Kyle Baley" <k...@baley.org> wrote:
> Thanks Billy. I have a related question that doesn't have anything to do
> with S#arp. If you remove the assemblies from the GAC, will the MVC
> templates still work?
>
> On Sat, Dec 13, 2008 at 12:34 PM, Billy <googlegro...@emccafferty.com>wrote:
>
>
>
> > The Northwind example and Visual Studio project template no longer
> > depend on ASP.NET MVC Beta being installed on your development
> > machine.  I.e., you can create and develop a project just fine without
> > installing the ASP.NET Beta.  The drawback is that you won't have the
> > Microsoft-provided ASP.NET MVC item templates available.  (But a
> > solution for even this conundrum is at
>
> >http://dylanbeattie.blogspot.com/2008/11/working-on-aspnet-mvc-beta-a...
> > .)
>
> > The source and project template at
>
> >https://sharp-architecture.googlecode.com/svn/trunk/TemplatesAndCodeG...
> > have been updated to reflect this change.  As the hillbilly eloquently
> > described at
> >http://codebetter.com/blogs/kyle.baley/archive/2008/12/12/asp-net-mvc...
> > ,

Kyle Baley

unread,
Dec 13, 2008, 1:35:15 PM12/13/08
to sharp-arc...@googlegroups.com
Suppose I could check myself. The reason I ask is: how would the templates know where to find the assemblies to reference them in the web project?

Billy

unread,
Dec 13, 2008, 1:45:05 PM12/13/08
to S#arp Architecture
Only one way to find out. ;)


On Dec 13, 11:35 am, "Kyle Baley" <k...@baley.org> wrote:
> Suppose I could check myself. The reason I ask is: how would the templates
> know where to find the assemblies to reference them in the web project?
>

Billy

unread,
Dec 17, 2008, 3:02:39 PM12/17/08
to S#arp Architecture
I just noticed a major drawback to removing {603c0e0b-db56-11dc-
be95-000d561079b0}; from the project GUIDs list in the csproj. You
lose all of the Microsoft MVC templates for the web project even if
ASP.NET MVC is installed. This seems to be a bit of a catch 22 unless
there's a way to enable MVC item templates for a project which doesn't
have the MVC GUID in its project file. Anybody know of a way to do
this?

Billy

Kyle Baley

unread,
Dec 17, 2008, 3:18:01 PM12/17/08
to sharp-arc...@googlegroups.com
That's a bit of a bummer. That said, I've been able to get along without the item templates pretty easily. Do they do anything other than derive from ViewPage instead of View?

Billy

unread,
Dec 17, 2008, 4:26:51 PM12/17/08
to S#arp Architecture
Heh, good point...they are pretty useless when I come to think about
it. ;)

Billy


On Dec 17, 1:18 pm, "Kyle Baley" <k...@baley.org> wrote:
> That's a bit of a bummer. That said, I've been able to get along without the
> item templates pretty easily. Do they do anything other than derive from
> ViewPage instead of View?
>
> On Wed, Dec 17, 2008 at 3:02 PM, Billy <googlegro...@emccafferty.com> wrote:
>
> > I just noticed a major drawback to removing {603c0e0b-db56-11dc-
> > be95-000d561079b0}; from the project GUIDs list in the csproj.  You
> > lose all of the Microsoft MVC templates for the web project even if
> > ASP.NET <http://asp.net/> MVC is installed.  This seems to be a bit of a
> > catch 22 unless
> > there's a way to enable MVC item templates for a project which doesn't
> > have the MVC GUID in its project file.  Anybody know of a way to do
> > this?
>
> > Billy
>
> > On Dec 13, 11:45 am, Billy <googlegro...@emccafferty.com> wrote:
> > > Only one way to find out. ;)
>
> > > On Dec 13, 11:35 am, "Kyle Baley" <k...@baley.org> wrote:
>
> > > > Suppose I could check myself. The reason I ask is: how would the
> > templates
> > > > know where to find the assemblies to reference them in the web project?
>
> > > > On Sat, Dec 13, 2008 at 1:16 PM, Billy <googlegro...@emccafferty.com>
> > wrote:
>
> > > > > My (almost positive) guess is that this would not have any impact on
> > > > > the availability and use of Microsoft provided ASP.NET<http://asp.net/>MVC item
> > > > > templates - but I have not confirmed this.  ;)
>
> > > > > Billy
>
> > > > > On Dec 13, 11:02 am, "Kyle Baley" <k...@baley.org> wrote:
> > > > > > Thanks Billy. I have a related question that doesn't have anything
> > to do
> > > > > > with S#arp. If you remove the assemblies from the GAC, will the MVC
> > > > > > templates still work?
>
> > > > > > On Sat, Dec 13, 2008 at 12:34 PM, Billy <
> > googlegro...@emccafferty.com
> > > > > >wrote:
>
> > > > > > > The Northwind example and Visual Studio project template no
> > longer
> > > > > > > depend on ASP.NET <http://asp.net/> MVC Beta being installed on
> > your development
> > > > > > > machine.  I.e., you can create and develop a project just fine
> > without
> > > > > > > installing the ASP.NET <http://asp.net/> Beta.  The drawback is
> > that you won't have the
> > > > > > > Microsoft-provided ASP.NET <http://asp.net/> MVC item templates

Alec Whittington

unread,
Dec 17, 2008, 4:43:41 PM12/17/08
to sharp-arc...@googlegroups.com
For those of us using Resharper, we can just make a live file template and use that to insert into the project. I actually have been doing this for a while since the controllers in my project inherit from a base controller. I really don't see this as a problem, maybe an inconvenience for some and it should be pointed out in the documents, but nothing to cry over IMHO.

Cheers
Alec Whittington

Kyle Baley

unread,
Dec 17, 2008, 11:55:44 PM12/17/08
to sharp-arc...@googlegroups.com
What about the Views? Is it possible to create one with ReSharper? I would imagine the fact that it's two (or three) files would make this nigh on impossible.
 
But now that I think about it, most of the time, my View doesn't even need a code-behind. It can just inherit from ViewPage<T> instead of my own type in the .aspx so a ReSharper template could be possible. A lot of the time, though, my model is a list of something and I am too lazy too look up the funky `[] CLR notation for generic types.

Alec Whittington

unread,
Dec 18, 2008, 12:22:26 AM12/18/08
to sharp-arc...@googlegroups.com
I complete forgot about the views, but for me not an issue as I use nHaml as the view engine.


Alec Whittington

Kyle Baley

unread,
Dec 19, 2008, 8:35:46 AM12/19/08
to sharp-arc...@googlegroups.com
As it turns out, this won't be an issue. Starting with RC1, Views won't have a code-behind file by default. And they now allow the standard ViewPage<MyModel> syntax in the Inherits attribute: http://weblogs.asp.net/scottgu/archive/2008/12/19/asp-net-mvc-design-gallery-and-upcoming-view-improvements-with-the-asp-net-mvc-release-candidate.aspx
 
Quite a few new interesting features in RC1, some of which (like the scaffolding) could impact S#arp. Is anyone able to get hold of the bits?

ema...@bilsimser.com

unread,
Dec 19, 2008, 8:43:11 AM12/19/08
to sharp-arc...@googlegroups.com
I can get them with my MVP secret decoder ring.

Sent from my BlackBerry device on the Rogers Wireless Network


From: "Kyle Baley"
Date: Fri, 19 Dec 2008 08:35:46 -0500
To: <sharp-arc...@googlegroups.com>
Subject: Re: Removed dependency on installed ASP.NET MVC Beta

Luis Abreu

unread,
Dec 19, 2008, 9:44:02 AM12/19/08
to sharp-arc...@googlegroups.com
Quite a few new interesting features in RC1, some of which (like the
scaffolding) could impact S#arp. Is anyone able to get hold of the bits?


Even if there is, I'm sure they won't be able to tell it to anyone...

Luis

Kyle Baley

unread,
Dec 19, 2008, 9:59:25 AM12/19/08
to sharp-arc...@googlegroups.com
But it means work could begin non-publicly on transitioning over to it.
Reply all
Reply to author
Forward
0 new messages