# C1.WPF.FlexGrid.C1FlexGridGroupPanel

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_WPF_FlexGrid_C1FlexGridGroupPanel" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel" class="text-break">C1FlexGridGroupPanel Class
</h1>
  <div class="markdown level0 summary"><p>Class that provides a UI for manipulating groups in a <a class="xref" href="../C1.WPF.FlexGrid.4.6.2/C1.WPF.FlexGrid.C1FlexGrid.html">C1FlexGrid</a>
control that is bound to an <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.icollectionview">ICollectionView</a>.</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <div class="inheritance">
    <h5>Inheritance</h5>
    <div class="level0"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></div>
    <div class="level1"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.threading.dispatcherobject">DispatcherObject</a></div>
    <div class="level2"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.dependencyobject">DependencyObject</a></div>
    <div class="level3"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.media.visual">Visual</a></div>
    <div class="level4"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.uielement">UIElement</a></div>
    <div class="level5"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.frameworkelement">FrameworkElement</a></div>
    <div class="level6"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.controls.control">Control</a></div>
    <div class="level7"><span class="xref">C1FlexGridGroupPanel</span></div>
  </div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.media.animation.ianimatable">IAnimatable</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.iframeworkinputelement">IFrameworkInputElement</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.iinputelement">IInputElement</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.isupportinitialize">ISupportInitialize</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.markup.iqueryambient">IQueryAmbient</a></div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.WPF.FlexGrid.html">C1.WPF.FlexGrid</a></h6>
  <h6><strong>Assembly</strong>: C1.WPF.FlexGrid.GroupPanel.4.6.2.dll</h6>
  <h5 id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">[TemplatePart(Name = &quot;Watermark&quot;, Type = typeof(TextBlock))]
[TemplatePart(Name = &quot;Markers&quot;, Type = typeof(StackPanel))]
public class C1FlexGridGroupPanel : Control, IAnimatable, IFrameworkInputElement, IInputElement, ISupportInitialize, IQueryAmbient</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">&lt;TemplatePart(Name:=&quot;Watermark&quot;, Type:=GetType(TextBlock))&gt;
&lt;TemplatePart(Name:=&quot;Markers&quot;, Type:=GetType(StackPanel))&gt;
Public Class C1FlexGridGroupPanel
    Inherits Control
    Implements IAnimatable, IFrameworkInputElement, IInputElement, ISupportInitialize, IQueryAmbient</code></pre>
  </div>
  <h5 id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_remarks"><strong>Remarks</strong></h5>
  <div class="markdown level0 remarks"><pre><code>&lt;p&gt;The &lt;xref href=&quot;C1.WPF.FlexGrid.C1FlexGridGroupPanel&quot; data-throw-if-not-resolved=&quot;false&quot;&gt;&lt;/xref&gt; is an independent element that is 
</code></pre>
<p>connected to a <a class="xref" href="../C1.WPF.FlexGrid.4.6.2/C1.WPF.FlexGrid.C1FlexGrid.html">C1FlexGrid</a> through the <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.FlexGrid.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_FlexGrid">FlexGrid</a>
property.</p>
<p>The <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.html">C1FlexGridGroupPanel</a> shows a panel and allows users to
create groups by dragging column headers into the panel. Users can reorder the
groups by dragging the group markers, or sort and remove groups by clicking
the group markers.</p>
<p>The appearance of the group markers is automatically determined by the grid
that is connected to the <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.html">C1FlexGridGroupPanel</a>. You don't have to
select any fonts or brushes.</p>
<p>The XAML below shows how you would create a <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.html">C1FlexGridGroupPanel</a>
and connect it to a grid:</p>
<pre><code>&lt;pre&gt;&lt;code class=&quot;lang-csharp&quot;&gt;&lt;c1:C1FlexGridGroupPanel 
  x:Name=&quot;_groupPanel&quot; Grid.Row=&quot;0&quot; Background=&quot;WhiteSmoke&quot;
  FlexGrid=&quot;{Binding ElementName=_flex}&quot;
  WatermarkText=&quot;Drag column headers here to create groups.&quot;
  MaxGroups=&quot;8&quot;
  HideGroupedColumns=&quot;True&quot;
  DragMarkerColor=&quot;#312DFF&quot; /&gt;&lt;/code&gt;&lt;/pre&gt;
</code></pre>
</div>
  <h3 id="constructors">Constructors
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel__ctor" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.#ctor">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.-ctor.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel__ctor">C1FlexGridGroupPanel()</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of a <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.html">C1FlexGridGroupPanel</a>.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="fields">Fields
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_DragMarkerColorProperty" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.DragMarkerColorProperty">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.DragMarkerColorProperty.html">DragMarkerColorProperty</a>
        </td>
        <td class="markdown level1 summary"><p>Identifies the <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.DragMarkerColor.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_DragMarkerColor">DragMarkerColor</a> dependency property.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_FlexGridProperty" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.FlexGridProperty">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.FlexGridProperty.html">FlexGridProperty</a>
        </td>
        <td class="markdown level1 summary"><p>Identifies the <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.FlexGrid.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_FlexGrid">FlexGrid</a> dependency property.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_HideGroupedColumnsProperty" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.HideGroupedColumnsProperty">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.HideGroupedColumnsProperty.html">HideGroupedColumnsProperty</a>
        </td>
        <td class="markdown level1 summary"><p>Identifies the <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.HideGroupedColumns.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_HideGroupedColumns">HideGroupedColumns</a> dependency property.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_MaxGroupsProperty" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.MaxGroupsProperty">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.MaxGroupsProperty.html">MaxGroupsProperty</a>
        </td>
        <td class="markdown level1 summary"><p>Identifies the <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.MaxGroups.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_MaxGroups">MaxGroups</a> dependency property.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="properties">Properties
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_DragMarkerColor" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.DragMarkerColor">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.DragMarkerColor.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_DragMarkerColor">DragMarkerColor</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the color used to show the drag and drop indicators.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_FlexGrid" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.FlexGrid">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.FlexGrid.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_FlexGrid">FlexGrid</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the <a class="xref" href="../C1.WPF.FlexGrid.4.6.2/C1.WPF.FlexGrid.C1FlexGrid.html">C1FlexGrid</a> that is connected to this
<a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.html">C1FlexGridGroupPanel</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_HideGroupedColumns" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.HideGroupedColumns">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.HideGroupedColumns.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_HideGroupedColumns">HideGroupedColumns</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets whether the control should automatically hide grouped columns.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_MaxGroups" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.MaxGroups">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.MaxGroups.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_MaxGroups">MaxGroups</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the maximum number of groups allowed.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_Watermark" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.Watermark">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.Watermark.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_Watermark">Watermark</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.controls.textblock">TextBlock</a> that shows the watermark in the empty group area.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_WatermarkText" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.WatermarkText">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.WatermarkText.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_WatermarkText">WatermarkText</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the message that appears in the empty group area.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="methods">Methods
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_OnApplyTemplate" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.OnApplyTemplate">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.OnApplyTemplate.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_OnApplyTemplate">OnApplyTemplate()</a>
        </td>
        <td class="markdown level1 summary"></td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_OnPropertyGroupCreated_C1_WPF_FlexGrid_PropertyGroupCreatedEventArgs_" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.OnPropertyGroupCreated(C1.WPF.FlexGrid.PropertyGroupCreatedEventArgs)">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.OnPropertyGroupCreated.html#C1_WPF_FlexGrid_C1FlexGridGroupPanel_OnPropertyGroupCreated_C1_WPF_FlexGrid_PropertyGroupCreatedEventArgs_">OnPropertyGroupCreated(PropertyGroupCreatedEventArgs)</a>
        </td>
        <td class="markdown level1 summary"><p>Raises the <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.PropertyGroupCreated.html">PropertyGroupCreated</a> event.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="events">Events
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_C1FlexGridGroupPanel_PropertyGroupCreated" data-uid="C1.WPF.FlexGrid.C1FlexGridGroupPanel.PropertyGroupCreated">
          <a class="xref" href="C1.WPF.FlexGrid.C1FlexGridGroupPanel.PropertyGroupCreated.html">PropertyGroupCreated</a>
        </td>
        <td class="markdown level1 summary"><p>Event that occurs when a new <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.data.propertygroupdescription">PropertyGroupDescription</a> has been created.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
