We want to fetch page names document type wise. Can any one please let us know the technique to use. Just for your information we are using Web Forms technique.
We are thinking of using this through user control in our custom project, i.e. not through umbraco site. Can any one please let us know the Umbraco DLLs we should refer in our project to do this?
Get Page Names For All Document Types
Hi All,
We want to fetch page names document type wise. Can any one please let us know the technique to use. Just for your information we are using Web Forms technique.
We are thinking of using this through user control in our custom project, i.e. not through umbraco site. Can any one please let us know the Umbraco DLLs we should refer in our project to do this?
Regards
Tarunjit Singh
Hello,
What version of Umbraco are you using? There are ways of doing this with the old and new api, but we first need to know the version you are using.
Jeroen
Hi Jeroen,
We are using Umbraco 7.2.1 version.
Regards
Tarunjit Singh
Hello,
If you are on a view and only want to get all published pages per documen type:
On a controller that inherits from the SurfaceController or RenderMvcController:
Also unpublished pages:
The id is the id of the document type.
You need the Umbraco.Core.dll and umbraco.dll file. You might need so some extra dll's for references, but you'll get those messages while building.
Jeroen
If you want to do it in a UserControl you should let your UserControl inherit from Umbraco.Web.UmbracoUserControl.
You can also get the current page like this:
Than you can use the second Controller example in a UserControl.
Jeroen
is working on a reply...