# C1.LiveLinq.LiveViewExtensions.AsLive

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_LiveLinq_LiveViewExtensions_AsLive_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive*">AsLive Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_LiveLinq_LiveViewExtensions_AsLive_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive*"></a>
<h4 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_C1_LiveLinq_IObservableSource___0__" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive``1(C1.LiveLinq.IObservableSource{``0})">AsLive&lt;T&gt;(IObservableSource&lt;T&gt;)</h4>
<div class="markdown level1 summary"><p>Creates a view based on the specified <a class="xref" href="C1.LiveLinq.IObservableSource-1.html">IObservableSource&lt;T&gt;</a> collection.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static View&lt;T&gt; AsLive&lt;T&gt;(this IObservableSource&lt;T&gt; source)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function AsLive(Of T)(source As IObservableSource(Of T)) As View(Of T)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.IObservableSource-1.html">IObservableSource</a>&lt;T&gt;</td>
      <td><span class="parametername">source</span></td>
      <td><p>The <a class="xref" href="C1.LiveLinq.IObservableSource-1.html">IObservableSource&lt;T&gt;</a> collection to expose as a view.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.View-1.html">View</a>&lt;T&gt;</td>
      <td><p>A view that contains the same elements as the <a class="xref" href="C1.LiveLinq.IObservableSource-1.html">IObservableSource&lt;T&gt;</a></p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="parametername">T</span></td>
      <td><p>The type of the elements in the collection.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_C1_LiveLinq_IObservableSource___0___remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>The resulting view may have its elements ordered differently than they are ordered in the <i>source</i> collection.
Correspondingly, views built on this resulting view (for example, if you filter it with <b>Where</b>) will not preserve the source order either.
If you need to preserve the source order, consider using the other <b>AsLive</b> overload where
you can specify to what extent you need the order to be preserved.</p>
</div>


<a id="C1_LiveLinq_LiveViewExtensions_AsLive_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive*"></a>
<h4 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_C1_LiveLinq_IObservableSource___0__C1_LiveLinq_LiveViews_ViewOrder_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive``1(C1.LiveLinq.IObservableSource{``0},C1.LiveLinq.LiveViews.ViewOrder)">AsLive&lt;T&gt;(IObservableSource&lt;T&gt;, ViewOrder)</h4>
<div class="markdown level1 summary"><p>Creates a view based on the specified <a class="xref" href="C1.LiveLinq.IObservableSource-1.html">IObservableSource&lt;T&gt;</a> collection.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static View&lt;T&gt; AsLive&lt;T&gt;(this IObservableSource&lt;T&gt; source, ViewOrder order)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function AsLive(Of T)(source As IObservableSource(Of T), order As ViewOrder) As View(Of T)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.IObservableSource-1.html">IObservableSource</a>&lt;T&gt;</td>
      <td><span class="parametername">source</span></td>
      <td><p>The <a class="xref" href="C1.LiveLinq.IObservableSource-1.html">IObservableSource&lt;T&gt;</a> collection to expose as a view.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.ViewOrder.html">ViewOrder</a></td>
      <td><span class="parametername">order</span></td>
      <td><p>Specifies whether to preserve source item order.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.View-1.html">View</a>&lt;T&gt;</td>
      <td><p>A view that contains the same elements as the <a class="xref" href="C1.LiveLinq.IObservableSource-1.html">IObservableSource&lt;T&gt;</a></p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="parametername">T</span></td>
      <td><p>The type of the elements in the collection.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_C1_LiveLinq_IObservableSource___0__C1_LiveLinq_LiveViews_ViewOrder__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>If the <i>order</i> parameter specifies preserving item order, the order of items in the source is preserved,
at a certain performance cost, in the resulting view and in views based on it (for example, if you filter it with <b>Where</b>).</p>
<p>Note that <b>Join</b> does not preserve source order. If you need to order a join result, use <b>OrderBy</b> after <b>Join</b>.</p>
</div>


<a id="C1_LiveLinq_LiveViewExtensions_AsLive_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive*"></a>
<h4 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_System_ComponentModel_IBindingList_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive``1(System.ComponentModel.IBindingList)">AsLive&lt;T&gt;(IBindingList)</h4>
<div class="markdown level1 summary"><p>Creates a view based on the specified <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a> data source.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static View&lt;T&gt; AsLive&lt;T&gt;(this IBindingList source)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function AsLive(Of T)(source As IBindingList) As View(Of T)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a></td>
      <td><span class="parametername">source</span></td>
      <td><p>The <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a> data source to expose as a view.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.View-1.html">View</a>&lt;T&gt;</td>
      <td><p>A view that contains the same elements as the <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a>.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="parametername">T</span></td>
      <td><p>The type of the elements in the view.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_System_ComponentModel_IBindingList__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Use this method to build views from existing data sources. The only requirements for the data source 
is that it implements the standard data binding interface <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a>.</p>
<p>The resulting view may have its elements ordered differently than they are ordered in the <i>source</i> collection.
Correspondingly, views built on this resulting view (for example, if you filter it with <b>Where</b>) will not preserve the source order either.
If you need to preserve the source order, consider using the other <b>AsLive</b> overload where 
you can specify to what extent you need the order to be preserved.</p>
</div>


<a id="C1_LiveLinq_LiveViewExtensions_AsLive_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive*"></a>
<h4 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_System_ComponentModel_IBindingList_C1_LiveLinq_LiveViews_ViewOrder_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive``1(System.ComponentModel.IBindingList,C1.LiveLinq.LiveViews.ViewOrder)">AsLive&lt;T&gt;(IBindingList, ViewOrder)</h4>
<div class="markdown level1 summary"><p>Creates a view based on the specified <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a> data source.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static View&lt;T&gt; AsLive&lt;T&gt;(this IBindingList source, ViewOrder order)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function AsLive(Of T)(source As IBindingList, order As ViewOrder) As View(Of T)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a></td>
      <td><span class="parametername">source</span></td>
      <td><p>The <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a> data source to expose as a view.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.ViewOrder.html">ViewOrder</a></td>
      <td><span class="parametername">order</span></td>
      <td><p>Specifies whether to preserve source item order.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.View-1.html">View</a>&lt;T&gt;</td>
      <td><p>A view that contains the same elements as the <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a>.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="parametername">T</span></td>
      <td><p>The type of the elements in the view.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_System_ComponentModel_IBindingList_C1_LiveLinq_LiveViews_ViewOrder__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>Use this method to build views from existing data sources. The only requirements for the data source 
is that it implements the standard data binding interface <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.ibindinglist">IBindingList</a>.</p>
<p>If the <i>order</i> parameter specifies preserving item order, the order of items in the source is preserved,
at a certain performance cost, in the resulting view and in views based on it (for example, if you filter it with <b>Where</b>).</p>
<p>Note that <b>Join</b> does not preserve source order. If you need to order a join result, use <b>OrderBy</b> after <b>Join</b>.</p>
</div>


<a id="C1_LiveLinq_LiveViewExtensions_AsLive_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive*"></a>
<h4 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_System_ComponentModel_BindingList___0__" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive``1(System.ComponentModel.BindingList{``0})">AsLive&lt;T&gt;(BindingList&lt;T&gt;)</h4>
<div class="markdown level1 summary"><p>A typed specialization of the <a class="xref" href="C1.LiveLinq.LiveViewExtensions.AsLive.html#C1_LiveLinq_LiveViewExtensions_AsLive__1_System_ComponentModel_IBindingList_">AsLive&lt;T&gt;(IBindingList)</a> method.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static View&lt;T&gt; AsLive&lt;T&gt;(this BindingList&lt;T&gt; source)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function AsLive(Of T)(source As BindingList(Of T)) As View(Of T)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.bindinglist-1">BindingList</a>&lt;T&gt;</td>
      <td><span class="parametername">source</span></td>
      <td><p>The <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.bindinglist-1">BindingList&lt;T&gt;</a> data source to expose as a view.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.View-1.html">View</a>&lt;T&gt;</td>
      <td><p>A view that contains the same elements as the <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.bindinglist-1">BindingList&lt;T&gt;</a>.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="parametername">T</span></td>
      <td><p>The type of the elements in the view.</p>
</td>
    </tr>
  </tbody>
</table>


<a id="C1_LiveLinq_LiveViewExtensions_AsLive_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive*"></a>
<h4 id="C1_LiveLinq_LiveViewExtensions_AsLive__1_System_ComponentModel_BindingList___0__C1_LiveLinq_LiveViews_ViewOrder_" data-uid="C1.LiveLinq.LiveViewExtensions.AsLive``1(System.ComponentModel.BindingList{``0},C1.LiveLinq.LiveViews.ViewOrder)">AsLive&lt;T&gt;(BindingList&lt;T&gt;, ViewOrder)</h4>
<div class="markdown level1 summary"><p>A typed specialization of the <a class="xref" href="C1.LiveLinq.LiveViewExtensions.AsLive.html#C1_LiveLinq_LiveViewExtensions_AsLive__1_System_ComponentModel_IBindingList_C1_LiveLinq_LiveViews_ViewOrder_">AsLive&lt;T&gt;(IBindingList, ViewOrder)</a> method.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static View&lt;T&gt; AsLive&lt;T&gt;(this BindingList&lt;T&gt; source, ViewOrder order)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function AsLive(Of T)(source As BindingList(Of T), order As ViewOrder) As View(Of T)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.bindinglist-1">BindingList</a>&lt;T&gt;</td>
      <td><span class="parametername">source</span></td>
      <td><p>The <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.bindinglist-1">BindingList&lt;T&gt;</a> data source to expose as a view.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.ViewOrder.html">ViewOrder</a></td>
      <td><span class="parametername">order</span></td>
      <td><p>Specifies whether to preserve source item order.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.LiveLinq.LiveViews.View-1.html">View</a>&lt;T&gt;</td>
      <td><p>A view that contains the same elements as the <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.bindinglist-1">BindingList&lt;T&gt;</a>.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="parametername">T</span></td>
      <td><p>The type of the elements in the view.</p>
</td>
    </tr>
  </tbody>
</table>
</div>
