Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
So I've setup my project according this tutorial: http://our.umbraco.org/wiki/codegarden-2009/open-space-minutes/working-in-visual-studio-when-developing-umbraco-solutions and I'm using umbraco 6.02.
So basically what I have is another web application ( not mvc ) where I want to create my razor scripts. However I do not have intellisense and visual studio doesn't understand the razor tags. Probably because my web application is not a MVC application, but I wonder if anyone has got this working, or has an alternative way for working with razor scripts in visual studio.
I don't know exactly what triggers Intellisense, but have had success developing razor scripts in Umbraco whether they are:
1. inline razor scripts in WebForms templates.
2. macros created in the Developer section of the Admin and pointing to a file in the /macroScripts folder. (also Umb webforms)
3. macros created in the Developer section of the Admin and pointing to a file in the /Views/MacroPartials that was also created in Developer section as a 'Partial View Macro File' (Umb MVC) I'm doing this for the first time today.
All I do is right click the file 'Open in Visual Studio' without even having a project or solution open and I get intellisense. You might want to try this newer instruction for working in Visual Studio, too. Maybe installing an MVC instance of Umbraco with NuGet will get the DLLs referenced somehow.
I've already got it working! In my seperate webapplication, I added a web.config and copied some lines from the web.config of the umbraco website to register assemblies.
@Khai Could you post the steps you followed to fix your issue please? I have the same problem (no intellisense, syntax highlighting or debugging for razor in VS 2013) and can't for the life of me figure out how to get it back! Thanks.
Hi Justin, ehm sorry I forgot exactly what lines you have to include in your web.config, but there were some lines for referencing MVC dlls. However I setup my umbraco projects differently now, I create an empty asp.net mvc 4 application and then use NuGet to install umbraco on top of it. I can highly recommend the nuget way to create your umbraco project. https://www.nuget.org/packages/UmbracoCms/
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted