Click or drag to resize
PageTypeFeaturesDocumentQueryExtensionsMenuItemsTQuery, TObject Method
Retrieves pages that have the flag DocumentShowInMenu set to true and their page type has the feature "Navigation item" enabled.

Namespace: CMS.DocumentEngine
Assembly: CMS.DocumentEngine (in CMS.DocumentEngine.dll) Version: 13.0.131
Syntax
C#
public static TQuery MenuItems<TQuery, TObject>(
	this IDocumentQuery<TQuery, TObject> query
)
where TQuery : Object, IDocumentQuery<TQuery, TObject>
where TObject : new(), TreeNode

Parameters

query
Type: CMS.DocumentEngineIDocumentQueryTQuery, TObject

Type Parameters

TQuery
Actual type of query being extended.
TObject
Actual type of TreeNode instance.

Return Value

Type: TQuery

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IDocumentQueryTQuery, TObject. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
Remarks

Note: This method is a data filter and can be used directly only to modify the DocumentQuery (e.g. DocumentHelper.GetDocuments().MenuItem()). It cannot be used as a part of where condition (e.g. DocumentHelper.GetDocuments().WhereContains("DocumentName", "Article").Or().MenuItem()).

See Also