<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-4235781500954729628</id><updated>2024-09-07T20:29:29.485-07:00</updated><category term="The SimpleListView webpart"/><title type='text'>Simple Web Parts</title><subtitle type='html'>About SharePoint features and solutions</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://simplewebparts.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4235781500954729628/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://simplewebparts.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Sal Carl</name><uri>http://www.blogger.com/profile/03056386081625971129</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>1</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4235781500954729628.post-6424700312147999053</id><published>2010-07-17T05:01:00.000-07:00</published><updated>2010-07-17T06:05:11.356-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="The SimpleListView webpart"/><title type='text'>The ListViewQuery webpart</title><content type='html'>This web part displays data using the&amp;nbsp;ListViewQuery&amp;nbsp;object model component. The ListViewByQuery control is part of the Microsoft.SharePoint&amp;nbsp;and is located in the Microsoft.SharePoint.WebControls namespace.&lt;br /&gt;
an example in C#:&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: lime;&quot;&gt;ListViewByQuery&lt;/span&gt; _view = &lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;new&lt;/span&gt; &lt;span class=&quot;Apple-style-span&quot; style=&quot;color: lime;&quot;&gt;ListViewByQuery&lt;/span&gt;();&lt;br /&gt;
&amp;nbsp;_view.List = &quot;List Title&quot;;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: lime;&quot;&gt;SPQuery&lt;/span&gt; _query = &lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;new &lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: lime;&quot;&gt;SPQuery&lt;/span&gt;(_view.List.Views[&quot;ListView&quot;]);&lt;br /&gt;
&amp;nbsp;_view.Query = _query;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;this&lt;/span&gt;.Controls.Add(_view);&lt;br /&gt;
&lt;br /&gt;
The idea is that you can create a list and its views at any level of your site collection and then use a very simple and intuitive custom webpart to display these views through the all site collection.&lt;br /&gt;
&lt;br /&gt;
Below is a scenario about how to use the webpart:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;You have a list/library at the root web of your site collection in which you store information about a series of countries called Country Profiles by Regions.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;You have a sub-site below your root web called Western Europe Region and you want to display data stored in the&amp;nbsp;Country Profiles by Regions library&amp;nbsp;previously&amp;nbsp;created on the root web.&lt;/li&gt;
&lt;/ul&gt;
So this is what you do:&lt;br /&gt;
&lt;br /&gt;
You go back to the root web of your site collection and create a view in the Country Profiles by Region list called Western Europe.&lt;br /&gt;
&lt;br /&gt;
You filter the view to only display countries belonging to the Western Europe Region.&lt;br /&gt;
You go back to the Western Europe Region sub-site and on the home page you drop the&amp;nbsp;ListViewQuery&amp;nbsp;webpart and display the newly created&amp;nbsp;view.&lt;br /&gt;
&lt;br /&gt;
&lt;div&gt;
&lt;a href=&quot;https://docs.google.com/leaf?id=0B8rhipdIBR8XZDUzYzYxM2UtYzcxOS00ZjRmLTg4ZjItYjhmNThlYjFmZDdl&amp;amp;hl=en&quot;&gt;Click here to download the solution&lt;/a&gt;&lt;br /&gt;
(After you download the folders extract all the files from the SimpleWebParts_1.0.zip to your SharePoint 2007 Server and follow the instructions from the&amp;nbsp;ListViewQuery-Installation-Guide.docx.&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, sans-serif;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, sans-serif;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, sans-serif;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, sans-serif;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, sans-serif;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, sans-serif;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, sans-serif;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, sans-serif;&quot;&gt;&lt;div&gt;
&lt;div&gt;
&lt;div&gt;
&lt;div&gt;
&lt;ul&gt;&lt;/ul&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://simplewebparts.blogspot.com/feeds/6424700312147999053/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4235781500954729628/6424700312147999053' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4235781500954729628/posts/default/6424700312147999053'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4235781500954729628/posts/default/6424700312147999053'/><link rel='alternate' type='text/html' href='http://simplewebparts.blogspot.com/2010/07/listviewquery-webpart.html' title='The ListViewQuery webpart'/><author><name>Sal Carl</name><uri>http://www.blogger.com/profile/03056386081625971129</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry></feed>