I was reading a book Pro Spring, which covers DI (Dependency Injection) and MVC on Java. I had the same feeling with peterkrantz, yes, too much configuration works. Rails is way better than that. How can Spring.net succeed?
Then I started looking for asp.net MVC framework, somebody is talking about MonoRail, others prefer Promesh.net, and castle… Finally, I realized that MonoRail is a part of castle open source project. In fact, I needed to install Castle Project assemblies to start playing with MonoRail.
After 2 hours lab, I was so pleased by its similarity to Ruby On Rails. Hope one day MS will adopt it as its official MVC framework to asp.net.
I had some compiling error/warning in my VS2005. “XML document cannot contain multiple root level elements.” in most of my vm(view) files, “Invalid token ‘Text’ at root level of document. ” for “#if($Flash.error)” statement. The web app runs OK with those errors. Later I removed those vm files and re-created one by one by selecting file type as ‘plain text’ instead of ‘HTML’, suddenly, all the errors went away.
4 Comments
Castle Project’s MonoRail MVC framework is simpler and cleaner than MVP but does so by abandoning the ASP.NET page lifecycle. Furthermore, MonoRail makes it more difficult to use third party ASP.NET user controls. But after trying it out, you may find both of these “drawbacks” being better than they first appear.
–Billy McCafferty http://www.codeproject.com/aspnet/ModelViewPresenter.asp
“Invalid token ‘Text’ at root level of document. ”
usually it’s you have a space after
OK
BAD
greetings
The problem is my VisualStudio treat all *.vm file as xml. How can I tell VS don’t using xml standard to compile vm?
Use Open With… and select HTML editor instead of XML one.