is it possible to inject the ipagedatacontext into a razor page. I've tried this@inject IPageDataContext@TreeNode@ pageDataContext
@h3@@pageDataContext.Page.Parent.DocumentName@/h3@
But I get this errorInvalidOperationException: No service for type 'Kentico.Content.Web.Mvc.IPageDataContext`1[CMS.DocumentEngine.TreeNode]' has been registered.
I'm just trying to get the parent document name.
↧