ModuleListPage.GetGroups(ModuleListPageGrouping) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the supported groupings.
protected:
virtual cli::array <System::Windows::Forms::ListViewGroup ^> ^ GetGroups(Microsoft::Web::Management::Client::ModuleListPageGrouping ^ grouping);
protected virtual System.Windows.Forms.ListViewGroup[] GetGroups (Microsoft.Web.Management.Client.ModuleListPageGrouping grouping);
abstract member GetGroups : Microsoft.Web.Management.Client.ModuleListPageGrouping -> System.Windows.Forms.ListViewGroup[]
override this.GetGroups : Microsoft.Web.Management.Client.ModuleListPageGrouping -> System.Windows.Forms.ListViewGroup[]
Protected Overridable Function GetGroups (grouping As ModuleListPageGrouping) As ListViewGroup()
Parameters
- grouping
- ModuleListPageGrouping
The name of the grouping.
Returns
The supported ListViewGroup objects.
Examples
The following example implements the GetGroups method to return two groups when the grouping is not null
.
class DemoPage : ModuleListPage {
public DemoPage() : base() { }
ModuleListPageGrouping _entryTypeGrouping;
private ModuleListPageSearchField[] _searchFields;
// contains filter string and a ModuleListPageFilter
private MyModuleListPageFilter _filter;
ModuleListPageFilter _selectedFilter;
string sDate = "8-2-07";
ModuleListPageGrouping GetMyGrouping() {
if (_entryTypeGrouping == null) {
_entryTypeGrouping = new ModuleListPageGrouping(
"Entry Type", "Entry Type");
}
return _entryTypeGrouping;
}
protected override ListViewGroup[] GetGroups(
ModuleListPageGrouping grouping) {
if (grouping != _entryTypeGrouping)
return null;
return new ListViewGroup[] {
_inheritedGroup,
_localGroup,
};
}
Remarks
The base class implementation returns null
.
Applies to
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for