# GrapeCity.ActiveReports.Design.Selection

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="GrapeCity_ActiveReports_Design_Selection" data-uid="GrapeCity.ActiveReports.Design.Selection" class="text-break">Selection Class
</h1>
  <div class="markdown level0 summary"><p>Represents a collection of selected components within the ActiveReports designer environment.</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"><span class="xref">Selection</span></div>
  </div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.icollection">ICollection</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.ienumerable">IEnumerable</a></div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="GrapeCity.ActiveReports.Design.html">GrapeCity.ActiveReports.Design</a></h6>
  <h6><strong>Assembly</strong>: MESCIUS.ActiveReports.Design.Win.dll</h6>
  <h5 id="GrapeCity_ActiveReports_Design_Selection_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public class Selection : ICollection, IEnumerable</code></pre>
  </div>
  <h5 id="GrapeCity_ActiveReports_Design_Selection_remarks"><strong>Remarks</strong></h5>
  <div class="markdown level0 remarks"><p>This class provides functionality to manage the selection of components in the designer. It allows querying the current selection, changing the selection,
and listening for selection changes. The selection can include controls, sections, or other design-time components. This class is particularly useful for
extending the designer's functionality or integrating with other parts of the application that need to react to changes in the designer's selection state.</p>
</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="GrapeCity_ActiveReports_Design_Selection__ctor_System_ComponentModel_Design_ISelectionService_" data-uid="GrapeCity.ActiveReports.Design.Selection.#ctor(System.ComponentModel.Design.ISelectionService)">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.-ctor.html#GrapeCity_ActiveReports_Design_Selection__ctor_System_ComponentModel_Design_ISelectionService_">Selection(ISelectionService)</a>
        </td>
        <td class="markdown level1 summary"><p>Constructs a new <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.html">Selection</a> instance using the provided selection service.</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="GrapeCity_ActiveReports_Design_Selection_Count" data-uid="GrapeCity.ActiveReports.Design.Selection.Count">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.Count.html#GrapeCity_ActiveReports_Design_Selection_Count">Count</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the number of components currently selected in the designer.</p>
</td>
      </tr>
      <tr>
        <td id="GrapeCity_ActiveReports_Design_Selection_IsSynchronized" data-uid="GrapeCity.ActiveReports.Design.Selection.IsSynchronized">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.IsSynchronized.html#GrapeCity_ActiveReports_Design_Selection_IsSynchronized">IsSynchronized</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value indicating whether access to the collection is synchronized (thread safe).</p>
</td>
      </tr>
      <tr>
        <td id="GrapeCity_ActiveReports_Design_Selection_Item_System_Int32_" data-uid="GrapeCity.ActiveReports.Design.Selection.Item(System.Int32)">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.Item.html#GrapeCity_ActiveReports_Design_Selection_Item_System_Int32_">this[int]</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieves the selected component at the specified index within the collection.</p>
</td>
      </tr>
      <tr>
        <td id="GrapeCity_ActiveReports_Design_Selection_SyncRoot" data-uid="GrapeCity.ActiveReports.Design.Selection.SyncRoot">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.SyncRoot.html#GrapeCity_ActiveReports_Design_Selection_SyncRoot">SyncRoot</a>
        </td>
        <td class="markdown level1 summary"><p>Gets an object that can be used to synchronize access to the collection.</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="GrapeCity_ActiveReports_Design_Selection_Clear" data-uid="GrapeCity.ActiveReports.Design.Selection.Clear">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.Clear.html#GrapeCity_ActiveReports_Design_Selection_Clear">Clear()</a>
        </td>
        <td class="markdown level1 summary"><p>Clears all selections within the designer.</p>
</td>
      </tr>
      <tr>
        <td id="GrapeCity_ActiveReports_Design_Selection_CopyTo_System_Array_System_Int32_" data-uid="GrapeCity.ActiveReports.Design.Selection.CopyTo(System.Array,System.Int32)">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.CopyTo.html#GrapeCity_ActiveReports_Design_Selection_CopyTo_System_Array_System_Int32_">CopyTo(Array, int)</a>
        </td>
        <td class="markdown level1 summary"><p>Copies the elements of the current selection into an array, starting at a particular array index.</p>
</td>
      </tr>
      <tr>
        <td id="GrapeCity_ActiveReports_Design_Selection_GetEnumerator" data-uid="GrapeCity.ActiveReports.Design.Selection.GetEnumerator">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.GetEnumerator.html#GrapeCity_ActiveReports_Design_Selection_GetEnumerator">GetEnumerator()</a>
        </td>
        <td class="markdown level1 summary"><p>Returns an enumerator that iterates through the collection of selected components.</p>
</td>
      </tr>
      <tr>
        <td id="GrapeCity_ActiveReports_Design_Selection_Select_System_Object_" data-uid="GrapeCity.ActiveReports.Design.Selection.Select(System.Object)">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.Select.html#GrapeCity_ActiveReports_Design_Selection_Select_System_Object_">Select(object)</a>
        </td>
        <td class="markdown level1 summary"><p>Replaces the current selection with the specified object.</p>
</td>
      </tr>
      <tr>
        <td id="GrapeCity_ActiveReports_Design_Selection_Select_System_Object_System_Boolean_" data-uid="GrapeCity.ActiveReports.Design.Selection.Select(System.Object,System.Boolean)">
          <a class="xref" href="GrapeCity.ActiveReports.Design.Selection.Select.html#GrapeCity_ActiveReports_Design_Selection_Select_System_Object_System_Boolean_">Select(object, bool)</a>
        </td>
        <td class="markdown level1 summary"><p>Adds the specified object to the current selection or makes it the primary selection.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
