Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • christopher muya 18 posts 200 karma points
    Aug 21, 2019 @ 03:12
    christopher muya
    0

    'Constants' is inaccessible due to its protection level

    I am trying to create a custom tree in umbraco 8.1.3 by following this tutorial https://our.umbraco.com/documentation/Extending/Section-Trees/trees. However, I get this error 'Constants' is inaccessible due to its protection level on this line: id == Constants.System.Root.ToInvariantString()

    Here are the namespaces Included in the class: using System; using System.Collections.Generic; using System.Linq; using System.Net.Http.Formatting; using System.Web; using System.Web.Http.ModelBinding; using Umbraco.Web.Actions; using Umbraco.Web.Models.Trees; using Umbraco.Web.Mvc; using Umbraco.Web.Trees; using Umbraco.Web.WebApi.Filters;

  • Dave de Moel 122 posts 574 karma points c-trib
    Aug 21, 2019 @ 09:54
    Dave de Moel
    0

    Make sure to use "using Umbraco.Core;"

  • christopher muya 18 posts 200 karma points
    Aug 21, 2019 @ 15:57
    christopher muya
    0

    Thank you so much!

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies