# C1.Win.FlexGrid.C1FlexGridBase.Transposed

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_Win_FlexGrid_C1FlexGridBase_Transposed_" data-uid="C1.Win.FlexGrid.C1FlexGridBase.Transposed*">Transposed Property
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_Win_FlexGrid_C1FlexGridBase_Transposed_" data-uid="C1.Win.FlexGrid.C1FlexGridBase.Transposed*"></a>
<h4 id="C1_Win_FlexGrid_C1FlexGridBase_Transposed" data-uid="C1.Win.FlexGrid.C1FlexGridBase.Transposed">Transposed</h4>
<div class="markdown level1 summary"><p>Gets or sets the grid transpose mode.
If set to true it flips the table so that rows become columns, and columns become rows, creating an inverted grid, but not grid data.</p>
<p>Sometimes, it is convenient to show data horizontally, as in the case when the entries (rows) are fewer than properties (columns).</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public bool Transposed { get; set; }</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Property Transposed As Boolean</code></pre>
</div>
<h5 id="C1_Win_FlexGrid_C1FlexGridBase_Transposed_remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Note, the filter by column will now appear to the left headers of the table.</p>
</div>
<h5 id="C1_Win_FlexGrid_C1FlexGridBase_Transposed_examples">Examples</h5>
<p>The transposition of the grid can be achieved as easy as setting the boolean value.</p>
<pre><code class="lang-csharp">var flexGrid = new C1.Win.FlexGrid.C1FlexGrid();
flexGrid.Transposed = true;</code></pre>
<p>Other properties can be considered to format and change some behaviors</p>
<pre><code class="lang-csharp">public void Initialize()
{
    //initialize object...
    C1FlexGrid c1FlexGrid1 = new C1.Win.FlexGrid.C1FlexGrid(); 

    //populate data...
    c1FlexGrid1.DataSource = Enumerable.Range(0, 100).Select(x =&gt; new Product()).ToList();

    //transpose...
    c1FlexGrid1.Transposed = true; 
}</code></pre>
<pre><code class="lang-csharp">public class Product
{
       static Random _rnd = new Random();
       static string[] _names = "Macko|Surfair|Pocohey|Studeby".Split('|');
       static string[] _lines = "Computers|Washers|Stoves|Cars".Split('|');
       static string[] _colors = "Red|Green|Blue|White".Split('|');

       public Product()
       {
            Name = _names[_rnd.Next() % _names.Length];
            Line = _lines[_rnd.Next() % _lines.Length];
            Color = _colors[_rnd.Next() % _colors.Length];
            Price = 30 + _rnd.NextDouble() * 1000;
            Cost = 3 + _rnd.NextDouble() * 300;
            Discontinued = _rnd.NextDouble() &lt; .2;
            Introduced = DateTime.Today.AddDays(_rnd.Next(-600, 0));
       }

       public string Name { get; set; }
       public string Color { get; set; }
       public string Line { get; set; }
       public double Price { get; set; }
       public double Cost { get; set; }
       public DateTime Introduced { get; set; }
       public bool Discontinued { get; set; }
}</code></pre>

</div>
