<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="http://syndication.webwiz.co.uk/rss_namespace/">
 <channel>
  <title>DevForce Community Forum : EntityQueryPagedCollectionView</title>
  <link>http://www.ideablade.com/forum/</link>
  <description>This is an XML content feed of; DevForce Community Forum : DevForce 2010 : EntityQueryPagedCollectionView</description>
  <pubDate>Mon, 13 Apr 2026 13:45:55 -700</pubDate>
  <lastBuildDate>Tue, 17 Jul 2012 11:36:22 -700</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 9.69</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>www.ideablade.com/forum/RSS_post_feed.asp?TID=3543</WebWizForums:feedURL>
  <image>
   <title>DevForce Community Forum</title>
   <url>http://www.ideablade.com/forum/forum_images/IdeaBlade_logo_tm.png</url>
   <link>http://www.ideablade.com/forum/</link>
  </image>
  <item>
   <title>EntityQueryPagedCollectionView : Thanks Denis.  I think your right...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=3543&amp;PID=14042#14042</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=579" rel="nofollow">gregweb</a><br /><strong>Subject:</strong> 3543<br /><strong>Posted:</strong> 17-Jul-2012 at 11:36am<br /><br />Thanks Denis.  I think your right in that I should create a new EM for the purpose.  That will keep things much cleaner.<br /><br /><br /><br />Greg]]>
   </description>
   <pubDate>Tue, 17 Jul 2012 11:36:22 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=3543&amp;PID=14042#14042</guid>
  </item> 
  <item>
   <title>EntityQueryPagedCollectionView : Hi Greg,The EQPCV is limited in...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=3543&amp;PID=14036#14036</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=912" rel="nofollow">DenisK</a><br /><strong>Subject:</strong> 3543<br /><strong>Posted:</strong> 16-Jul-2012 at 6:49pm<br /><br />Hi Greg,<div><br></div><div>The EQPCV is limited in functionality and not intended for a full CRUD operation. Not having a .Clear method is one such limitation.</div><div><br></div><div>Having said that, another workaround that I can think of to clear the list is set the EntityQuery.QueryStrategy to CacheOnly, call EntityManager.Clear() and call EQPCV.Refresh()</div><div><br></div><div><table width="99%"><tr><td><pre class="BBcode"></div><div><div>_query = _entityManager.Customers;</div><div><br></div><div>View = new EntityQueryPagedCollectionView(</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;_query, &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;// Source of data</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;PageSize, &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // Page size</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;PageSize, &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // Load size - no lookahead caching here&nbsp;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;true, &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // Whether to defer the load</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;false); &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // Whether to add primary key to sort columns</div></div><div><br></div><div>//other operations.........</div><div><br></div><div>//Clear here</div><div>ClearEQPCV();</div><div><br></div><div>//other operations........</div><div><br></div><div>//Set QueryStrategy back when done</div><div>_query.QueryStrategy = QueryStrategy.Normal; &nbsp; &nbsp; //or _entityManager.DefaultQueryStrategy</div><div><br></div><div><div>public void ClearEQPCV() {</div><div>&nbsp; &nbsp; &nbsp; _query.QueryStrategy = QueryStrategy.CacheOnly; &nbsp; &nbsp; &nbsp;</div><div>&nbsp; &nbsp; &nbsp; _entityManager.Clear();</div><div>&nbsp; &nbsp; &nbsp; View.Refresh();</div><div>}</div></div><div></pre></td></tr></table></div><div><br></div><div>This essentially tricks the EQPCV query to look into an empty EM cache. Depending on your needs, you might want to create a separate edit EM for this purpose.</div><div><br></div><div>Hope this helps.</div><span style="font-size:10px"><br /><br />Edited by DenisK - 16-Jul-2012 at 6:56pm</span>]]>
   </description>
   <pubDate>Mon, 16 Jul 2012 18:49:34 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=3543&amp;PID=14036#14036</guid>
  </item> 
  <item>
   <title>EntityQueryPagedCollectionView : I have a EntityQueryPagedCollectionView....</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=3543&amp;PID=14032#14032</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=579" rel="nofollow">gregweb</a><br /><strong>Subject:</strong> 3543<br /><strong>Posted:</strong> 16-Jul-2012 at 10:07am<br /><br />I have a EntityQueryPagedCollectionView.  When a user wants to filter the list, I use a PredicateDescription and EQPCV.SetQueryFilter.  This works fine.<br /><br />However, when the user want to add a number of items to the list, I want to start with a cleared list, ie nothing in the list.<br /><br />I don't see a way of doing this.  There is no EQPCV.Clear() method. The only thing I can think of is creating a bogus PredicateDescription so it will return nothing. The problem with this, though, is that then when items are added, they disappear of the list after a save as they don't match the PD.<br /><br />Greg<span style="font-size:10px"><br /><br />Edited by gregweb - 16-Jul-2012 at 10:16am</span>]]>
   </description>
   <pubDate>Mon, 16 Jul 2012 10:07:26 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=3543&amp;PID=14032#14032</guid>
  </item> 
 </channel>
</rss>