Built An MVC Application Using XSL As The View Engine?
Feb 11, 2011if anyone has built an MVC application using XSL as the view engine? One of my aims is to allow the designer to create multiple skins using xsl files.
View 3 Repliesif anyone has built an MVC application using XSL as the view engine? One of my aims is to allow the designer to create multiple skins using xsl files.
View 3 RepliesHow to integrate Razor view engine into mvc 2 web application?
View 3 Replies point me in the direction of getting the Razor View Engine working correctly with an empty "non MVC" web application. I can correctly set it up with a MVC app or with a Web Site (Razor), but if I try and get it running with and empty app, I run into the following two problems:
1) I can't add new razor files to the application (*.cshtml files)
2) Once deployed to AppHarbor, the .cshtml files aren't found unless they have the extension specified (i.e. /Default won't work, but /Default.cshtml does)
If I look at the Razor View Engine, then I see a very nice and concise syntax that is not particularly tied to generating html. So I wonder, how easy would it be to use the engine outside asp.net in a "normal" .net environment for example to generate text, code,...
View 3 Replieshow to fix "Method not found: 'Void System.Web.Mvc.ViewContext..ctor(System.Web.Mvc.ControllerContext, System.Web.Mvc.IView, System.Web.Mvc.ViewDataDictionary, System.Web.Mvc.TempDataDictionary)'." exception. This solution doesn't work http://dotnetslackers.com/articles/aspnet/installing-the-spark-view-engine-into-asp-net-mvc-2-preview-2.aspx.
View 3 RepliesAs ASP.NET MVC has a pluggable view engine architecture, and XAML is an object descriptive mark-up that, given the right processor/ parser, can generate an appropriate UI...are there plans/ efforts to create a view engine that can turn XAML into HTML?
Personally, I think this would help to re-enforce the efforts the WPF/ Silverlight people have gone to in providing a means of seperating the view from the model/ business logic between designers and developers (via Visual Studio and Expression Blend)...
Seems like a logical step to me, but not knowing XAML as well as I should, I'm wondering if feasable, or even relevant.
I have used the xslt code from Steven Sandersons book 'Pro ASP.NET MVC2 Framework' for the xslt view engine and that is working perfectly. However I am now looking at using a master page for the header, footer, and navigation sections and only need to use my other xslt files to populate the content part.
View 3 RepliesI tried searching a bit and didn't find an answer. Does the Razor View Engine work in Mono?
View 3 RepliesI'm working trying to realize a requirement where the pages should be 'configurable' at runtime (per client), stored in a database - a requirement that I have no say in Anyway, the current plan is to use the Razor view engine and 'load' the 'pages' dynamically. I have a basic sample working using a VirtualPathProvider and VirtualFile that serves up Raz'pages' on the fly.The question I have if there is a better approach when I have the Razor 'pages' stored in a dB (or any other repository)?
There seems to be some constraints and concerns when I check other postings. For example:'If a Web site is precompiled for deployment, content provided by a VirtualPathProvider instance is not compiled, and noVirtualPathProvider instances are used by the precompiled site.'
(from http://msdn.microsoft.com/en-us/library/system.web.hosting.virtualpathprovider.aspx )
I am working on a MVC project with Razor view engine and I have the following:
[Code]....
This only works if I have on the same view the following:
[Code]....
So if "SquishIt.Framework" namespace is added on Web.Config why do I need to have the @using on the view?
I have an asp:DataGrid with templated columns. Here's one of those columns:
<asp:TemplateColumn>
<ItemTemplate>
<asp:LinkButton ID="btnDetails"
Runat="server"
CommandName="details"
Text="Details"
Font-Size="0.8em"
CommandArgument='a=<%# Eval("a")%>&b=<%# Eval("b")%>' />
<...>
When the command fires, the CommandArgument comes back unevaluated - it is the string a=<%# Eval("a")%>&b=<%# Eval("b")%>, not a=5&b=6 as I want. What's wrong with how I'm doing this?
I was going through the spark view engine documentation and found a lot of literals showing up in code for which I couldn't find any references. For e.g. ! , #, $ , !$ , ... What are these for? What do the combinations mean? When do they come into use? Am I missing any more literals that precede or comes after {
View 3 RepliesIs there any way to use placeholder similar to WebForms in NVelocity View Engine (.vm files)? Today I've got a component containing everything for the <head>, but I wish to specify additional tags from each view page like it can easily be done in ASP.NET WebForms / MVC:
<asp:Content ID="Content2" ContentPlaceHolderID="head" runat="server"></asp:Content>
If this is not possible directly trough NVelocity View Engine, do I have any other alternatives other than using a blank MasterPage and adding all markup in each view page?
Trying out the Razor view engine and for some reason my generic helper methods are breaking. For example:
public static class UrlHelperExtensions
{
public static string NonGenericHelper(this UrlHelper helper, Type controller)
{
return controller.Name;
}
public static string GenericHelper<TController>(this UrlHelper helper)
{
return typeof(TController).Name;
}
}
Works as expected:@Url.NonGenericHelper(typeof(ProjectEuler.UI.Models.Home))Breaks with the following exception:
@Url.GenericHelper<ProjectEuler.UI.Models.Home>()
"CS1502: The best overloaded method match for 'Microsoft.WebPages.WebPageUltimateBase.Write(Microsoft.WebPages.Helpers.HelperResult)'
has some invalid arguments"
The only workaround I could find is treating it as a "multi-token
statement":
@(Url.GenericHelper<ProjectEuler.UI.Models.Home>())
Not sure if this is the intended behavior or just a bug but it would be nice to be able to call a generic method as you would a non generic one.
Inside VS 2010 I do not have any intellisense working. I have reinstalled everything and still nothing is coming up for intellisense?
View 2 RepliesI just downloaded and installed Web Matrix beta.
I am really liking the razor view engine.
Not so much the Web Matrix IDE.
Is there any way to install razor view engine for use in the Visual Studio without installing WebMatrix?
how do I change the view engine from aspx to razor in an existing project? If I just change the file extension to cshtml I always get "The controller for path '/path/About' was not found or does ..."
View 2 RepliesHow do you modify a ASP.NET MVC 2.0 project to work with the Spark View Engine?
I tried like described here:
[URL]
But somehow it still tries to route to .aspx files.
Here the code of my global.asax:
public class MvcApplication : System.Web.HttpApplication
{
public static void RegisterRoutes(RouteCollection routes)
{
routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
routes.MapRoute(.......
How to create responsive web application in asp.net.
I want textbox,dropdownlist, button, gridview, etc. everything responsive.
I tried using bootstap css file but its not working.
Where i can find documentation about expressions and syntax of WebForms view engine?And what is the difference between <%: expression %> and <%= expression %>
View 2 RepliesI try to use HtmlHelper.TextBoxFor with spark view engine but view crashed with exception "Dynamic view compilation failed. 'System.Web.Mvc.HtmlHelper' does not contain a definition for 'TextBoxFor' and no extension method 'TextBoxFor' accepting a first argument of type 'System.Web.Mvc.HtmlHelper' could be found(are you missing a using directive or an assembly reference?)".
It is my _global.spark:
<use namespace="System"/>
<use namespace="System.Linq"/>
<use namespace="System.Text" />
<use namespace="System.Web.Mvc"/>
<use namespace="System.Web.Mvc.Html"/>
<use namespace="System.Web.Routing"/>
<use namespace="System.Linq.Expressions" />
<use namespace="MyModels" />
In spark-view using:
${Html.TextBoxFor(m => m.UserName)}
On my projects I am using Razor View engine and I need to define custom Partial folders:
[Code]....
I had this because there was a problem in MVC 3 Preview. Was it corrected?
How should I register the Partial Views in MVC 3 Beta?
I'm running into a weird issue that I can't find an answer for anywhere I've looked (and I've looked a ton).I built a web deployment project with Visual Studio 2008 Team System on my old Win XP machine. This has always worked flawlessly and installed everywhere. I can also copy this MSI to my new Windows 7 Ultimate machine and it again installs just fine.
HOWEVER, when I rebuild that exact same web deployment project on my new Win7 machine, also using VS2008, the MSI will build OK, but when I then run it to install my software I get a dialog box telling me "the installer was interrupted." Interestingly, when I built this MSI in my new environment one additional warning popped up during the build process, which was "Unable to copy the schema file '(null)'"After many searches and reading different web pages, I know this has to do with these two registry keys:
[HKEY_LOCAL_MACHINESOFTWAREMicrosoftVisualStudio9.0DeploymentSchema]
"DefaultMSISchemaFile"="c:\Program Files\Microsoft Visual Studio 9.0\Common7\Tools\Deployment\Vspkgs\..\VsdSchema\Schema.msi"
"DefaultMSMSchemaFile"="c:\Program Files\Microsoft Visual Studio 9.0\Common7\Tools\Deployment\Vspkgs\..\VsdSchema\Schema.msm"
Yet, everything checks out. All permissions are correctly configured, etc., etc.Then, when I enable the built-in administrator account and log in as that, and then rebuild this same web deployment MSI the "Unable to copy the schema file '(null)'" warning no longer appears. Then when I log back out, log back in as myself and then run this newly built MSI it installs fine, just like the original one that was built on XP.I also tried uninstalling VS2008 and re-installing it as the super user, but that also didn't change anything. And yes, I did also configure devenv.exe to run as administrator.
Has anybody seen this? Or is it a requirement that you can only compile deployment projects as the super user? That cannot be right.I've been thrashing for more than five days and for the life of me cannot figure this out. Of course, I can run as the super user when developing, but I thought the new security model in Win7 was designed exactly so you don't have to.
Is it possible to built a feature in a asp.net application which will let the user schedule things that would be run on the background?
For instance, say that there is a option in the application to send a email to every customer in the system on their birthaday. The user from the system could activate the option in the application, and for as long as the option is activated the system queries
every day if some customers birthday is on that day and then send a email to that customer.
I think it has to integrate with the taskscheduler, but i don;t know how to integrate that dynamicly in a application
WCF service is running with 'wsHttpBinding' Binding. The application which gonna consume WCF Service is non-wcf compliance or in other words, it is on the top of Framework 2.0 and I can't use ServiceModel in this app (since only 3.5 supports ServiceModel).
how to consume above WCF Service in application built in 2.0?