Umbraco 6 Fresh Install - CS0234: The type or namespace name 'Cms' does not exist in the namespace 'Umbraco'
I've got this issue on a fresh Version 6 Install. Installed from the binary.
Error is:
Error occured
c:\DEVELOPMENT\Sites\despangler.local\WEB\macroScripts\634979334878453971_verb_conjugation_overview.cshtml(2): error CS0234:The type ornamespace name 'Cms' does not exist in the namespace'Umbraco'(are you missing an assembly reference?)
A razor script with just the following:
@inheritsPartialViewMacroPage
Throws this error:
Error occured
c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\a17adf73\5eaf38dc\App_Web_634979339575648376_verb_conjugation_overview.cshtml.70df5e80.uhjl3jj1.0.cs(29): error CS0246:The type ornamespace name 'PartialViewMacroPage' could not be found (are you missing a using directive or an assembly reference?)
Thanks Owen, a decent suggestion but that's not it. The main issue seems to be with the Umbraco.Cms namespace (I still get the first error mentioned with the following code):
@inherits PartialViewMacroPage
@using Umbraco.Cms.Web
@using Umbraco.Cms.Web.Macros
@using Umbraco.Framework
@* Ensure that the Current Page has children *@
@if (CurrentPage.Children.Any())
{
This is what was in the "List Descendants from Current Page" template. I'm guessing this is wrong for V6.. Are there any Razor guides for V6 anywhere? I've tried to poke around in some of the binaries included in V6 and can't find the namespaces mentioned above... can somebody point me in the right direction, please?
Umbraco 6 Fresh Install - CS0234: The type or namespace name 'Cms' does not exist in the namespace 'Umbraco'
I've got this issue on a fresh Version 6 Install. Installed from the binary.
Error is:
A razor script with just the following:
Throws this error:
Any idea what is wrong?
Thanks, Greg
Missing the namespace, the full name should be "Umbraco.Web.Macros.PartialViewMacroPage"
Thanks Owen, a decent suggestion but that's not it. The main issue seems to be with the Umbraco.Cms namespace (I still get the first error mentioned with the following code):
This is what was in the "List Descendants from Current Page" template. I'm guessing this is wrong for V6.. Are there any Razor guides for V6 anywhere? I've tried to poke around in some of the binaries included in V6 and can't find the namespaces mentioned above... can somebody point me in the right direction, please?
Okay, fixed. The template should not have had the 3 using statements at the top, and it should have inherited
instead of
Also, it should reference Model instead of CurrentPage.
Perhaps a core developer would like to fix the templates in V6??
is working on a reply...