<?xml version="1.0" encoding="utf-8"?><rss version="2.0"><channel><title>Mavention</title><link>http://www.mavention.nl/rss</link><description></description><ttl>60</ttl><item><title>Mavention ontwikkelt nieuwe website Amsterdam RAI</title><link>http://www.mavention.nl/nieuws/Pages/mavention-ontwikkelt-nieuwe-website-amsterdam-rai.aspx</link><description>​&lt;span&gt;&lt;strong&gt;Amsterdam RAI heeft Mavention gevraagd een nieuwe website te ontwikkelen met SharePoint 2010. De nieuwe website moet de verschillende doelgroepen van Amsterdam RAI beter met elkaar verbinden, door meer gebruik van community functies, doelgroepgerichte informatie en inspirerend beeldmateriaal.&lt;/strong&gt;&lt;br /&gt;&lt;br /&gt;Mavention ontwikkelt de nieuwe website met SharePoint 2010 en de nieuwste technieken, zoals HTML5. De website wordt geoptimaliseerd voor toegankelijkheid, search en performance. Verschillend producten van Mavention worden hierbij ingezet. Als basis voor de SharePoint oplossing wordt Mavention Flex Layout gebruikt. Daarnaast worden ook andere WCM producten van Mavention ingezet. &lt;br /&gt;&lt;br /&gt;Mavention is inmiddels gestart met het project en verwacht de nieuwe website in april op te leveren.&lt;br /&gt;&lt;br /&gt;Meer informatie over het ontwikkelen van websites met SharePoint? Neem dan &lt;a href="/pages/contact.aspx"&gt;contact&lt;/a&gt; op met Joris Engels.&lt;/span&gt;</description><pubDate>Wed, 22 Feb 2012 16:36:19 GMT</pubDate></item><item><title>Speaking at the SharePoint Saturday Holland</title><link>http://www.mavention.nl/blog/Pages/speaking-sharepoint-saturday-holland.aspx</link><description>&lt;p&gt;On March 24 there will be &lt;a href="http://sharepointsaturday.org/nl/default.aspx"&gt;the next edition of SharePoint Saturday Holland&lt;/a&gt;. I have the honor of presenting two sessions for SharePoint developers.&lt;/p&gt;
&lt;h2&gt;Diwug.nl v2 – How we did it&lt;/h2&gt;
&lt;p&gt;Recently me and &lt;a href="/over-ons/pages/default.aspx"&gt;fellow Mavens&lt;/a&gt; built &lt;a href="http://www.diwug.nl/Pages/default.aspx"&gt;a new website for the Dutch Information Worker User Group&lt;/a&gt;. This website uses HTML5, is accessible and, what’s the most important, is built on the Microsoft SharePoint 2010 platform. In this session, that I will co-presenting with &lt;a href="http://blog.octavie.nl/"&gt;Octavie van Haaften&lt;/a&gt;, we are going to show you how we built the new website for DIWUG.&lt;/p&gt;
&lt;h2&gt;Optimizing SharePoint 2010 websites for search engines&lt;/h2&gt;
&lt;p&gt;Whenever you build a public-facing website you want people to find it. Although your website will eventually be indexed by search engines by itself, there are ways for you to help search engines discover the content on your website. In this session I will share with you some tips and tricks in how you can optimize your public-facing website built on the SharePoint 2010 platform for search engines.&lt;/p&gt;
&lt;h2&gt;About SharePoint Saturday Holland&lt;/h2&gt;
&lt;p&gt;Join SharePoint architects, developers, and other professionals that work with Microsoft SharePoint Server 2010 for ‘SharePoint Saturday’ event.  SharePoint Saturday is an educational, informative &amp;amp; lively day filled with sessions from respected SharePoint professionals &amp;amp; MVPs, covering a wide variety of SharePoint-orientated topics.  SharePoint Saturday is FREE, open to the public and is your local chance to immerse yourself in SharePoint!&lt;/p&gt;
&lt;p&gt;See you on the &lt;a href="http://sharepointsaturday.org/nl/default.aspx"&gt;SharePoint Saturday Holland&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt;Originally posted at &lt;a href="http://blog.mastykarz.nl/speaking-sharepoint-saturday-holland/?utm_source=mavention&amp;amp;utm_medium=preview&amp;amp;utm_campaign=Mavention Blog"&gt;http://blog.mastykarz.nl/speaking-sharepoint-saturday-holland/&lt;/a&gt;&lt;/p&gt;</description><pubDate>Wed, 22 Feb 2012 08:19:42 GMT</pubDate></item><item><title>Speaking at The International SharePoint Conference London 2012</title><link>http://www.mavention.nl/blog/Pages/speaking-international-sharepoint-conference-london-2012.aspx</link><description>&lt;p&gt;During the upcoming &lt;a href="http://www.internationalsharepointconference.com/Pages/Default.aspx"&gt;International SharePoint Conference London 2012&lt;/a&gt; I will be co-presenting three sessions in the developer track.&lt;/p&gt;
&lt;h2&gt;Project Startup DEV202&lt;/h2&gt;
&lt;p&gt;In &lt;a href="http://www.internationalsharepointconference.com/Pages/Sessions.aspx#DEV202"&gt;the Project Startup DEV202 session&lt;/a&gt;, that I will be co-presenting with &lt;a href="http://www.wictorwilen.se/"&gt;fellow SharePoint MVP and SharePoint MCM Wictor Wilén&lt;/a&gt;, Wictor and I will be discussing different approaches to structure your solution and make to help you get the most of the Visual Studio 2010 SharePoint Developer Tools .&lt;/p&gt;
&lt;h2&gt;Deployment Process – Creating web templates, setup lifecycle management and deployment parts 1 (DEV206) and 2 (DEV207)&lt;/h2&gt;
&lt;p&gt;Later in the developer track I will be co-presenting two sessions (&lt;a href="http://www.internationalsharepointconference.com/Pages/Sessions.aspx#DEV206"&gt;DEV206&lt;/a&gt; and &lt;a href="http://www.internationalsharepointconference.com/Pages/Sessions.aspx#DEV207"&gt;DEV207&lt;/a&gt;) with &lt;a href="http://sharepointchick.com/"&gt;fellow SharePoint MVP and SharePoint MCM Mirjam van Olst&lt;/a&gt;. In our sessions Mirjam and I will be discussing the process of packaging different pieces of the solution that we will be working with so that you can support all the different requirements during the whole lifecycle of the project.&lt;/p&gt;
&lt;h2&gt;The Developer Track&lt;/h2&gt;
&lt;p&gt;This year the developer track will be organized in a different way than previously (quoted from &lt;a href="http://www.internationalsharepointconference.com/Pages/Track-Overviews.aspx"&gt;the ISC site&lt;/a&gt;):&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;This track is for all the Developers out there who are just starting a SharePoint journey of discovery and for those developers who have been developing for a while and now need to hone their skills to a more advanced level. There is so much that you can do with SharePoint where do you start, and what is the correct way to take a design all the way through to a finished solution deployed live in your production farm. The Developer track in 2012 will be a unique track with a complete 3 day focus on taking a concept all the way through its build, test and deployment process and showing how in the real world what situations a developer can come across and how those situations are troubleshot and resolved. Unlike normal session based conferences this year we plan on expanding on the basic knowledge and going as deep as is needed, so if a topic needs 2 sessions to cover it thoroughly then 2 sessions will be scheduled so you get all the information you need when you go back to the office. &lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;As you can see, instead of giving separate presentations we will be aiming at giving you a more complete insight into the process and hopefully share with you more knowledge that you can benefit of in your every day's work.&lt;/p&gt;
&lt;p&gt;I’m looking forward to &lt;a href="http://combined-knowledge.com/isc2012/Event_Registration.html"&gt;seeing you in London&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt;Originally posted at &lt;a href="http://blog.mastykarz.nl/speaking-international-sharepoint-conference-london-2012/?utm_source=mavention&amp;amp;utm_medium=preview&amp;amp;utm_campaign=Mavention Blog"&gt;http://blog.mastykarz.nl/speaking-international-sharepoint-conference-london-2012/&lt;/a&gt;&lt;/p&gt;</description><pubDate>Wed, 22 Feb 2012 07:27:43 GMT</pubDate></item><item><title>changing the application pool for existing web applications</title><link>http://www.mavention.nl/blog/Pages/changing-the-application-pool-for-existing-web-applications.aspx</link><description>&lt;p&gt;There are many articles about SharePoint 2010 and application pool management. One of those topics is the number of application pools to be used by your SharePoint web applications.  I like this post by Todd Klindt: &lt;a href="http://www.sharepointpromag.com/content1/topic/sharepoint-2010-misconfigurations-141636/catpath/sharepoint/page/3" target="_blank"&gt;Top 10 SharePoint 2010 Configuration Mistakes&lt;/a&gt;. Mistake #5 is about application pools and web applications. There’s no need to have an application pool for each web application. Sharing an application pool by several web applications saves you lots of megabytes of memory.&lt;/p&gt;
&lt;p&gt;With Central Administration it is undoable to set a different application pool for a web application. First, you have to delete the web application without deleting the IIS site and content databases. Then you can recreate the web application using the correct application pool, the existing IIS site and finally attaching the content databases. If you have features activated at the web application scope, you also have to reactivate them again and Lord knows what happens then!&lt;/p&gt;
&lt;p&gt;You don’t want this. No, you don’t.&lt;/p&gt;
&lt;p&gt;Alternative? PowerShell of course! Basically you will need a reference to the application pool first, then a reference to the web application and then you can update the ApplicationPool property.&lt;/p&gt;
&lt;p&gt;At one of my customer’s SharePoint Farm I noticed that every web application had it’s own Application Pool. What a waste of resources that is. Time for scripting, I guess.&lt;/p&gt;
&lt;p&gt;Here’s my PowerShell Script:&lt;/p&gt;
&lt;div&gt;&lt;div class="syntaxhighlighter  ps ie" id="highlighter_70673"&gt;&lt;table border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="gutter"&gt;&lt;div class="line number1 index0 alt2"&gt;1&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;2&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;3&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;4&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;5&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;6&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;7&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;8&lt;/div&gt;
&lt;div class="line number9 index8 alt2"&gt;9&lt;/div&gt;
&lt;div class="line number10 index9 alt1"&gt;10&lt;/div&gt;
&lt;div class="line number11 index10 alt2"&gt;11&lt;/div&gt;
&lt;div class="line number12 index11 alt1"&gt;12&lt;/div&gt;
&lt;div class="line number13 index12 alt2"&gt;13&lt;/div&gt;
&lt;div class="line number14 index13 alt1"&gt;14&lt;/div&gt;
&lt;div class="line number15 index14 alt2"&gt;15&lt;/div&gt;
&lt;div class="line number16 index15 alt1"&gt;16&lt;/div&gt;
&lt;div class="line number17 index16 alt2"&gt;17&lt;/div&gt;
&lt;div class="line number18 index17 alt1"&gt;18&lt;/div&gt;
&lt;div class="line number19 index18 alt2"&gt;19&lt;/div&gt;
&lt;div class="line number20 index19 alt1"&gt;20&lt;/div&gt;
&lt;div class="line number21 index20 alt2"&gt;21&lt;/div&gt;
&lt;div class="line number22 index21 alt1"&gt;22&lt;/div&gt;
&lt;div class="line number23 index22 alt2"&gt;23&lt;/div&gt;
&lt;div class="line number24 index23 alt1"&gt;24&lt;/div&gt;
&lt;div class="line number25 index24 alt2"&gt;25&lt;/div&gt;
&lt;div class="line number26 index25 alt1"&gt;26&lt;/div&gt;
&lt;div class="line number27 index26 alt2"&gt;27&lt;/div&gt;
&lt;div class="line number28 index27 alt1"&gt;28&lt;/div&gt;
&lt;div class="line number29 index28 alt2"&gt;29&lt;/div&gt;
&lt;div class="line number30 index29 alt1"&gt;30&lt;/div&gt;
&lt;div class="line number31 index30 alt2"&gt;31&lt;/div&gt;
&lt;div class="line number32 index31 alt1"&gt;32&lt;/div&gt;
&lt;div class="line number33 index32 alt2"&gt;33&lt;/div&gt;
&lt;div class="line number34 index33 alt1"&gt;34&lt;/div&gt;
&lt;div class="line number35 index34 alt2"&gt;35&lt;/div&gt;
&lt;div class="line number36 index35 alt1"&gt;36&lt;/div&gt;
&lt;div class="line number37 index36 alt2"&gt;37&lt;/div&gt;
&lt;div class="line number38 index37 alt1"&gt;38&lt;/div&gt;
&lt;div class="line number39 index38 alt2"&gt;39&lt;/div&gt;
&lt;div class="line number40 index39 alt1"&gt;40&lt;/div&gt;
&lt;div class="line number41 index40 alt2"&gt;41&lt;/div&gt;
&lt;div class="line number42 index41 alt1"&gt;42&lt;/div&gt;
&lt;div class="line number43 index42 alt2"&gt;43&lt;/div&gt;
&lt;div class="line number44 index43 alt1"&gt;44&lt;/div&gt;
&lt;div class="line number45 index44 alt2"&gt;45&lt;/div&gt;
&lt;div class="line number46 index45 alt1"&gt;46&lt;/div&gt;
&lt;div class="line number47 index46 alt2"&gt;47&lt;/div&gt;
&lt;div class="line number48 index47 alt1"&gt;48&lt;/div&gt;
&lt;div class="line number49 index48 alt2"&gt;49&lt;/div&gt;
&lt;div class="line number50 index49 alt1"&gt;50&lt;/div&gt;
&lt;div class="line number51 index50 alt2"&gt;51&lt;/div&gt;&lt;/td&gt;
&lt;td class="code"&gt;&lt;div class="container"&gt;&lt;div class="line number1 index0 alt2"&gt;&lt;code class="ps value"&gt;$config&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps keyword"&gt;Get-Content&lt;/code&gt; &lt;code class="ps keyword"&gt;Set&lt;/code&gt;&lt;code class="ps keyword"&gt;-DefaultApplicationPoolConfig&lt;/code&gt;&lt;code class="ps plain"&gt;.xml&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;&lt;code class="ps value"&gt;$defaultAppPoolName&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$config&lt;/code&gt;&lt;code class="ps plain"&gt;.WebApplications.defaultAppPoolName&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt; &lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;&lt;code class="ps plain"&gt;[Void][System.Reflection.Assembly]::LoadWithPartialName(&lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Microsoft.SharePoint&amp;quot;&lt;/code&gt;&lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;&lt;code class="ps plain"&gt;[Void][System.Reflection.Assembly]::LoadWithPartialName(&lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Microsoft.SharePoint.Administration&amp;quot;&lt;/code&gt;&lt;code class="ps plain"&gt;) &lt;/code&gt;&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt; &lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;&lt;code class="ps value"&gt;$service&lt;/code&gt; &lt;code class="ps plain"&gt;= [Microsoft.SharePoint.Administration.SPWebService]::ContentService &lt;/code&gt;&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt; &lt;/div&gt;
&lt;div class="line number9 index8 alt2"&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps string"&gt;&amp;quot;Checking presence default application pool $defaultAppPoolName...&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number10 index9 alt1"&gt; &lt;/div&gt;
&lt;div class="line number11 index10 alt2"&gt;&lt;code class="ps plain"&gt;[Microsoft.SharePoint.Administration.SPApplicationPool] &lt;/code&gt;&lt;code class="ps value"&gt;$newAppPool&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$service&lt;/code&gt;&lt;code class="ps plain"&gt;.ApplicationPools[&lt;/code&gt;&lt;code class="ps value"&gt;$defaultAppPoolName&lt;/code&gt;&lt;code class="ps plain"&gt;] &lt;/code&gt;&lt;/div&gt;
&lt;div class="line number12 index11 alt1"&gt; &lt;/div&gt;
&lt;div class="line number13 index12 alt2"&gt;&lt;code class="ps comments"&gt;## The Default Application Pool MUST exist!&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number14 index13 alt1"&gt;&lt;code class="ps plain"&gt;if(&lt;/code&gt;&lt;code class="ps value"&gt;$newAppPool&lt;/code&gt; &lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$NULL&lt;/code&gt;&lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number15 index14 alt2"&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number16 index15 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps string"&gt;&amp;quot;&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number17 index16 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Red &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;The default application pool '$defaultAppPoolName' does not exist.&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number18 index17 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Red &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Please ensure the application pool '$defaultAppPoolName' is already registered in SharePoint.&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number19 index18 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;exit&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number20 index19 alt1"&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number21 index20 alt2"&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number22 index21 alt1"&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number23 index22 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Green &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;[OK]&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number24 index23 alt1"&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number25 index24 alt2"&gt; &lt;/div&gt;
&lt;div class="line number26 index25 alt1"&gt;&lt;code class="ps keyword"&gt;foreach&lt;/code&gt;&lt;code class="ps plain"&gt;( &lt;/code&gt;&lt;code class="ps value"&gt;$webAppConfig&lt;/code&gt; &lt;code class="ps plain"&gt;in &lt;/code&gt;&lt;code class="ps value"&gt;$config&lt;/code&gt;&lt;code class="ps plain"&gt;.WebApplications.WebApplication )&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number27 index26 alt2"&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number28 index27 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps value"&gt;$url&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$webAppConfig&lt;/code&gt;&lt;code class="ps plain"&gt;.url&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number29 index28 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps string"&gt;&amp;quot;Updating $url...&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number30 index29 alt1"&gt; &lt;/div&gt;
&lt;div class="line number31 index30 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps value"&gt;$webApp&lt;/code&gt; &lt;code class="ps plain"&gt;= Get&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPWebApplication&lt;/code&gt; &lt;code class="ps value"&gt;$url&lt;/code&gt; &lt;code class="ps keyword"&gt;-ErrorAction&lt;/code&gt; &lt;code class="ps plain"&gt;SilentlyContinue&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number32 index31 alt1"&gt; &lt;/div&gt;
&lt;div class="line number33 index32 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$webApp&lt;/code&gt; &lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$null&lt;/code&gt; &lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number34 index33 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number35 index34 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot; [Web application does not exist]&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number36 index35 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;continue&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number37 index36 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number38 index37 alt1"&gt; &lt;/div&gt;
&lt;div class="line number39 index38 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps value"&gt;$currentAppPool&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$webApp&lt;/code&gt;&lt;code class="ps plain"&gt;.ApplicationPool&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number40 index39 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if(&lt;/code&gt;&lt;code class="ps value"&gt;$currentAppPool&lt;/code&gt;&lt;code class="ps plain"&gt;.Name &lt;/code&gt;&lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$defaultAppPoolName&lt;/code&gt;&lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number41 index40 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number42 index41 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Green &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot; [Change not needed]&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number43 index42 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number44 index43 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number45 index44 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number46 index45 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$webApp&lt;/code&gt;&lt;code class="ps plain"&gt;.ApplicationPool = &lt;/code&gt;&lt;code class="ps value"&gt;$newAppPool&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number47 index46 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$webApp&lt;/code&gt;&lt;code class="ps plain"&gt;.Update()&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number48 index47 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$webApp&lt;/code&gt;&lt;code class="ps plain"&gt;.ProvisionGlobally()&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number49 index48 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Green &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot; [Done]&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number50 index49 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number51 index50 alt2"&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;As you can see this script uses a XML configuration file. In this file I configure what the default application pool name is and which web applications I want to change to this application pool.&lt;/p&gt;
&lt;p&gt;XML Configuration file:&lt;/p&gt;
&lt;div&gt;&lt;div class="syntaxhighlighter  xml ie" id="highlighter_715993"&gt;&lt;table border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="gutter"&gt;&lt;div class="line number1 index0 alt2"&gt;1&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;2&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;3&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;4&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;5&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;6&lt;/div&gt;&lt;/td&gt;
&lt;td class="code"&gt;&lt;div class="container"&gt;&lt;div class="line number1 index0 alt2"&gt;&lt;code class="xml plain"&gt;&amp;lt;&lt;/code&gt;&lt;code class="xml keyword"&gt;WebApplications&lt;/code&gt; &lt;code class="xml color1"&gt;defaultAppPoolName&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;SharePoint - Default Web Application Pool&amp;quot;&lt;/code&gt; &lt;code class="xml plain"&gt;&amp;gt;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;&lt;code class="xml spaces"&gt;    &lt;/code&gt;&lt;code class="xml plain"&gt;&amp;lt;&lt;/code&gt;&lt;code class="xml keyword"&gt;WebApplication&lt;/code&gt; &lt;code class="xml color1"&gt;url&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;&lt;a href="http://dummy.ochadev.local/"&gt;http://dummy.ochadev.local&lt;/a&gt;&amp;quot;&lt;/code&gt; &lt;code class="xml plain"&gt;/&amp;gt;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;&lt;code class="xml spaces"&gt;    &lt;/code&gt;&lt;code class="xml plain"&gt;&amp;lt;&lt;/code&gt;&lt;code class="xml keyword"&gt;WebApplication&lt;/code&gt; &lt;code class="xml color1"&gt;url&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;&lt;a href="http://redactie.diwug.local/"&gt;http://redactie.diwug.local&lt;/a&gt;&amp;quot;&lt;/code&gt; &lt;code class="xml plain"&gt;/&amp;gt;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;&lt;code class="xml spaces"&gt;    &lt;/code&gt;&lt;code class="xml plain"&gt;&amp;lt;&lt;/code&gt;&lt;code class="xml keyword"&gt;WebApplication&lt;/code&gt; &lt;code class="xml color1"&gt;url&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;&lt;a href="http://playground.ochadev.local/"&gt;http://playground.ochadev.local&lt;/a&gt;&amp;quot;&lt;/code&gt; &lt;code class="xml plain"&gt;/&amp;gt;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;&lt;code class="xml spaces"&gt;    &lt;/code&gt;&lt;code class="xml plain"&gt;&amp;lt;&lt;/code&gt;&lt;code class="xml keyword"&gt;WebApplication&lt;/code&gt; &lt;code class="xml color1"&gt;url&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;&lt;a href="http://testdummy/"&gt;http://testdummy&lt;/a&gt;&amp;quot;&lt;/code&gt; &lt;code class="xml plain"&gt;/&amp;gt;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;&lt;code class="xml plain"&gt;&amp;lt;/&lt;/code&gt;&lt;code class="xml keyword"&gt;WebApplications&lt;/code&gt;&lt;code class="xml plain"&gt;&amp;gt;&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;And this is the result:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.octavie.nl/wp-content/uploads/2012/02/Set-DefaultApplicationPool.png"&gt;&lt;img width="244" height="123" title="Set-DefaultApplicationPool" alt="Set-DefaultApplicationPool" src="http://blog.octavie.nl/wp-content/uploads/2012/02/Set-DefaultApplicationPool_thumb.png" border="0" style="background-image:none;margin:5px;display:inline" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;After executing the script the SharePoint web applications are registered with the new default application pool. This also means that whenever you extend your farm with a new SharePoint server, it also has the correct web applications and their application pools.&lt;/p&gt;
&lt;p&gt;Good luck and enjoy.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.octavie.nl/wp-content/uploads/2012/02/Set-DefaultApplicationPool.zip"&gt;Download script&lt;/a&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Originally posted at &lt;a href="http://blog.octavie.nl/index.php/2012/02/21/changing-application-pool-for-existing-web-applications/"&gt;http://blog.octavie.nl/index.php/2012/02/21/changing-application-pool-for-existing-web-applications/&lt;/a&gt;&lt;/p&gt;</description><pubDate>Tue, 21 Feb 2012 08:33:59 GMT</pubDate></item><item><title>Modifying views of a List View Web Part in a Sandboxed Solution</title><link>http://www.mavention.nl/blog/Pages/modifying-views-list-view-web-part-sandboxed-solution.aspx</link><description>&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/inconvenient-provisioning-web-parts-wiki-pages-sandboxed-solutions/"&gt;In my recent article I showed you how to declaratively provision List View Web Parts to pages from within a Sandboxed Solution&lt;/a&gt;. Since the default view is often not what you want and creating a List Definition just to get the right view for the List View Web Part is way too much overhead, what is the easiest approach to modify a view of a List View Web Part in a Sandboxed Solution?&lt;/p&gt;
&lt;p&gt;The challenge when working with List View Web Parts (LVWP), or any other Web Part for that matter, from within a Sandboxed Solution is that the &lt;a href="http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.webpartpages.splimitedwebpartmanager.aspx?ocid=aff-n-we-loc--ITPRO40936&amp;amp;WT.mc_id=aff-n-we-loc--ITPRO40936"&gt;SPLimitedWebPartManager&lt;/a&gt; class is not available. This makes it impossible to programmatically modify any of the Web Part’s properties after it has been added to a page. Although most Web Parts can be provisioned preconfigured, it’s the List View Web Part that makes things challenging. Because you cannot access the LVWP, you cannot change the view that the Web Part is using, or can you?&lt;/p&gt;
&lt;h2&gt;BinarySerializedWebPart&lt;/h2&gt;
&lt;p&gt;One of the changes in SharePoint 2010 is storing saved Site Templates as SharePoint Packages (WSP). To support provisioning preconfigured List View Web Part the &lt;a href="http://msdn.microsoft.com/en-us/library/ff625793.aspx?ocid=aff-n-we-loc--ITPRO40936&amp;amp;WT.mc_id=aff-n-we-loc--ITPRO40936"&gt;BinarySerializedWebPart&lt;/a&gt; element has been introduced. Stefan Stanev has &lt;a href="http://stefan-stanev-sharepoint-blog.blogspot.com/2010/06/sharepoint-2010-binaryserializedwebpart.html"&gt;a good article describing the whole process&lt;/a&gt; and Peter Holpar has &lt;a href="http://pholpar.wordpress.com/category/binaryserializedwebpart/"&gt;a series of articles dedicated to working with the BinarySerializedWebPart&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Although the BinarySerializedWebPart works and will get you the right results, it’s rather inconvenient to use. First of all, because the Web Part is serialized, it’s hard to tell what its contents are. This is particularly important when multiple developers are working on the solution. Another challenge that the BinarySerializedWebPart introduces, is that it’s nearly impossible to maintain the BinarySerializedWebPart. Probably the only convenient way of doing it would be to have the Web Part provisioned to a page, apply the required changes, and export the Web Part again.&lt;/p&gt;
&lt;p&gt;There is however another approach that you might consider.&lt;/p&gt;
&lt;h2&gt;Anatomy of a List View&lt;/h2&gt;
&lt;p&gt;If you have ever taken a closer look at List Views, you might have noticed the &lt;a href="http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spview.url.aspx?ocid=aff-n-we-loc--ITPRO40936&amp;amp;WT.mc_id=aff-n-we-loc--ITPRO40936"&gt;Url&lt;/a&gt; property. Although it might not seem like much it turns out that for views used by the List View Web Part, the Url property contains the URL of the page on which the List View Web Part using that particular view is located!&lt;/p&gt;
&lt;p&gt;As shown in the figure below, a List View Web Part for the standard &lt;em&gt;Announcements&lt;/em&gt; List added to the &lt;em&gt;SitePages/Home.aspx&lt;/em&gt; page would create a hidden View in the &lt;em&gt;Announcements&lt;/em&gt; List with the Url property set to &lt;em&gt;SitePages/Home.aspx&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/Modifying-views-of-a-List-View-Web-Part-_70AC/01.jpg"&gt;&lt;img width="480" height="323" alt="Arrows pointing from a List View Web Part on a SharePoint 2010 Wiki Page to the address bar in the browser and a list of views in a PowerShell window" src="http://blog.mastykarz.nl/images/Modifying-views-of-a-List-View-Web-Part-_70AC/01_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Given this, all we have to do, to modify the List View Web Part’s View, is to get a reference to the &lt;em&gt;Announcements&lt;/em&gt; List, get a reference to the right View, apply our changes and update the view: all of which can be perfectly done from within a Sandboxed Solution!&lt;/p&gt;
&lt;h2&gt;Programmatically changing List View Web Part’s View&lt;/h2&gt;
&lt;p&gt;The perfect place for applying changes to a LVWP’s View is the Feature Receiver of a Feature that provisions that LVWP to a page. The following code snippet shows how you can modify the view of a List View Web Part pointing to the standard Announcements List.&lt;/p&gt;
&lt;pre class="brush: csharp;"&gt;using System;
using System.Linq;
using System.Runtime.InteropServices;
using Microsoft.SharePoint;

namespace WebPartsFromSandbox.Features.Pages {
    [Guid(&amp;quot;8645cbdd-101a-4866-9701-8957975238e4&amp;quot;)]
    public class PagesEventReceiver : SPFeatureReceiver {
        public override void FeatureActivated(SPFeatureReceiverProperties properties) {
            SPWeb web = properties.Feature.Parent as SPWeb;

            if (web != null) {
                ChangeViewFieldsForAView(web, web.RootFolder.WelcomePage, &amp;quot;Announcements&amp;quot;, new string[] { &amp;quot;Title&amp;quot; });
            }
        }

        private static void ChangeViewFieldsForAView(SPWeb web, string pageUrl, string listName, string[] viewFields) {
            SPList list = web.Lists[listName];
            SPView view = (from SPView vw
                           in list.Views
                           where vw.Url == pageUrl
                           select vw).FirstOrDefault();

            if (view != null) {
                view.ViewFields.DeleteAll();

                foreach (string viewFieldName in viewFields) {
                    view.ViewFields.Add(viewFieldName);
                }

                view.Update();
            }
        }
    }
}&lt;/pre&gt;
&lt;p&gt;After executing this code you should see the standard view of a List View Web Part pointing to the &lt;em&gt;Announcements&lt;/em&gt; List changed to show only the &lt;em&gt;Title&lt;/em&gt; column.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/Modifying-views-of-a-List-View-Web-Part-_70AC/02.jpg"&gt;&lt;img width="480" height="296" alt="Announcements List View Web Part with modified view on a SharePoint 2010 Wiki Page" src="http://blog.mastykarz.nl/images/Modifying-views-of-a-List-View-Web-Part-_70AC/02_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;As you can see the code required to modify a the view of a List View Web Part is simple. We start with retrieving a reference to the List with which the LVWP is associated (line 18). Next, from the list of all available Views we retrieve the View that is used by the LVWP. We use the Url property to determine which View that is (lines 19-22). In this sample all we do, is to change the fields visible in the View. We do this by first removing all fields (line 25) and then we add all fields that we want to be visible in the View (lines 27-29). When done we confirm our changes by calling the List’s Update method (line 31).&lt;/p&gt;
&lt;h2&gt;Summary&lt;/h2&gt;
&lt;p&gt;One of the frequent challenges when provisioning List View Web Part from within Sandboxed Solutions is the inability to modify the view used by the Web Part. Using the fact the URL of the View created by the LVWP points to the page where the LVWP is located you can easily retrieve that View and modify it to meet your requirements.&lt;/p&gt;
&lt;p&gt;Originally posted at &lt;a href="http://blog.mastykarz.nl/modifying-views-list-view-web-part-sandboxed-solution/?utm_source=mavention&amp;amp;utm_medium=preview&amp;amp;utm_campaign=Mavention Blog"&gt;http://blog.mastykarz.nl/modifying-views-list-view-web-part-sandboxed-solution/&lt;/a&gt;&lt;/p&gt;</description><pubDate>Fri, 10 Feb 2012 09:19:51 GMT</pubDate></item><item><title>Mavention spreekt op SharePoint Conference in London</title><link>http://www.mavention.nl/nieuws/Pages/mavention-spreekt-sharePoint-conference-london.aspx</link><description>​&lt;span lang="EN-US"&gt;&lt;strong&gt;Op 23 april 2012 vertelt &lt;/strong&gt;&lt;a href="/over-ons/pages/waldek-mastykarz.aspx" target="_blank"&gt;&lt;strong&gt;Waldek Mastykarz&lt;/strong&gt;&lt;/a&gt;&lt;strong&gt; de best practices voor de inrichting van SharePoint Solutions op de The International SharePoint Conference London 2012. &lt;/strong&gt;&lt;/span&gt;&lt;span lang="EN-US"&gt;&lt;/span&gt;&lt;div&gt;&lt;span&gt;&lt;br /&gt;De SharePoint conference in Londen wordt dit jaar voor de vierde keer gehouden. Niet alleen de naam (voorheen: ‘best practices’) maar ook de opzet is dit jaar anders. In drie dagen tijd wordt een volledig project uitgevoerd. Door de verschillende programmaonderdelen heen wordt een kennismanagement oplossing ontwikkeld. &lt;/span&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;span&gt;&lt;br /&gt;Het opzetten van een SharePoint solution is de basis voor vrijwel ieder project. &lt;span style="font-family:'calibri', 'sans-serif';font-size:11pt"&gt;Waldek Mastykarz geeft tijdens één van de eerste tracks op de conferentie een presentatie over dit onderwerp&lt;/span&gt; (&lt;a href="http://www.internationalsharepointconference.com/Pages/Sessions.aspx#DEV202" target="_blank"&gt;DEV202&lt;/a&gt;): ‘Hoe haal je het meeste uit de developer tools die op de markt zijn?’ Waldek geeft deze presentatie samen met &lt;a href="http://www.internationalsharepointconference.com/Pages/Speakers.aspx#wictorwilen" target="_blank"&gt;Wictor Wilén&lt;/a&gt;. Wictor is net als Waldek SharePoint MVP (Most Valuable Professional) en houdt zich voornamelijk met SharePoint ontwikkeling bezig.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.internationalsharepointconference.com/Pages/default.aspx" target="_blank"&gt;Meer informatie over de SharePoint conference in Londen vindt u hier.&lt;/a&gt;&lt;/span&gt;</description><pubDate>Sat, 11 Feb 2012 14:53:15 GMT</pubDate></item><item><title>Inconvenient provisioning Web Parts to Wiki Pages in Sandboxed Solutions</title><link>http://www.mavention.nl/blog/Pages/inconvenient-provisioning-web-parts-wiki-pages-sandboxed-solutions.aspx</link><description>&lt;p&gt;Sandboxed Solutions are a powerful way to create SharePoint 2010 Solutions in a secure manner. The price of security however is limited access to the SharePoint API which makes it challenging to accomplish certain tasks like provisioning Web Parts to Wiki Pages. Find out how to provision Web Parts to Wiki Pages in Sandboxed Solutions.&lt;/p&gt;
&lt;h2&gt;Playing in the Sandbox&lt;/h2&gt;
&lt;p&gt;The introduction of Sandbox in SharePoint 2010 empowers both IT-Pros and Developers. Using Sandboxed Solutions developers can deliver rich solutions that leverage the SharePoint 2010 capabilities. Because those solutions are executed in an isolated fashion and have limited access to the SharePoint API and the .NET Framework, there are less risks involved with deploying and using them in a SharePoint Farm. One more important benefit of using Sandboxed Solutions is, that they require less involvement from IT departments as they can be deployed and managed by Site Collection Administrators.&lt;/p&gt;
&lt;p&gt;In SharePoint 2007, where no Sandbox was available, designing SharePoint Solutions was a lot like all or nothing: either developers were allowed to create solutions with custom code and had virtually access to the full SharePoint API and .NET Framework or SharePoint Farms were sealed, no custom code would be allowed and developers were tasked with the challenge to get things to work using nothing more than the standard functionality of the SharePoint platform. As you can imagine neither of those two approaches is perfect. Allowing developers to use the full API means you have to spend more time on security-testing their work and narrowing the options to standard functionality only means that not the solution but the technical capabilities are central and there is a chance that business might get not the solution that they need, not to mention the extra effort required to “just get things done”.&lt;/p&gt;
&lt;p&gt;Sandboxed Solutions offer added value to SharePoint developers allowing them to use their knowledge to build secure solutions. And although the API available for Sandboxed Solutions gives developers the ability to interact with data stored in SharePoint, it might be too limited to complete all tasks and provide end users with fully working solutions instead of a collection of building blocks and a manual.&lt;/p&gt;
&lt;h2&gt;Inconvenient provisioning Web Parts instances from Sandboxed Solutions&lt;/h2&gt;
&lt;p&gt;One of the challenges when working with Sandboxed Solutions is how to provision Web Parts instances to pages. If you have done this before in a Farm Solution you know, that in order to add a Web Part to a page programmatically in SharePoint you have to retrieve the instance of the &lt;a href="http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.webpartpages.splimitedwebpartmanager.aspx?ocid=aff-n-we-loc--ITPRO40936&amp;amp;WT.mc_id=aff-n-we-loc--ITPRO40936"&gt;SPLimitedWebPartManager&lt;/a&gt; class and use it to add the instance of a Web Part to a page. Unfortunately, as the SDK mentions, the SPLimitedWebPartManager class is not available in Sandboxed Solutions which means that you cannot programmatically add a Web Part to a page from within a Sandboxed Solution.&lt;/p&gt;
&lt;p&gt;Luckily the programmatic approach isn’t the only option that SharePoint offers for adding Web Parts to pages. It turns out that there is a declarative approach as well, which is just perfect for when you need to provision a Web Part instance from within a Sandboxed Solution.&lt;/p&gt;
&lt;h3&gt;Declaratively provisioning Web Part instances to pages&lt;/h3&gt;
&lt;p&gt;Declaratively provisioning Web Part instances to pages is easy and can be done using a Module. The following code snippet shows how you can add a Content Editor Web Part with the &lt;em&gt;Hello world&lt;/em&gt; text to a Web Part Page:&lt;/p&gt;
&lt;pre class="brush: xml;"&gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;
&amp;lt;Elements xmlns=&amp;quot;http://schemas.microsoft.com/sharepoint/&amp;quot;&amp;gt;
  &amp;lt;Module Name=&amp;quot;HomePage&amp;quot;&amp;gt;
    &amp;lt;File Path=&amp;quot;HomePage\default.aspx&amp;quot; Url=&amp;quot;default.aspx&amp;quot;&amp;gt;
      &amp;lt;AllUsersWebPart WebPartOrder=&amp;quot;0&amp;quot; WebPartZoneID=&amp;quot;Left&amp;quot;&amp;gt;
        &amp;lt;![CDATA[&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;
&amp;lt;WebPart xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot; xmlns:xsd=&amp;quot;http://www.w3.org/2001/XMLSchema&amp;quot; xmlns=&amp;quot;http://schemas.microsoft.com/WebPart/v2&amp;quot;&amp;gt;
  &amp;lt;Title&amp;gt;Content Editor&amp;lt;/Title&amp;gt;
  &amp;lt;FrameType&amp;gt;Default&amp;lt;/FrameType&amp;gt;
  &amp;lt;Description&amp;gt;Allows authors to enter rich text content.&amp;lt;/Description&amp;gt;
  &amp;lt;IsIncluded&amp;gt;true&amp;lt;/IsIncluded&amp;gt;
  &amp;lt;ZoneID&amp;gt;Left&amp;lt;/ZoneID&amp;gt;
  &amp;lt;PartOrder&amp;gt;0&amp;lt;/PartOrder&amp;gt;
  &amp;lt;FrameState&amp;gt;Normal&amp;lt;/FrameState&amp;gt;
  &amp;lt;Height /&amp;gt;
  &amp;lt;Width /&amp;gt;
  &amp;lt;AllowRemove&amp;gt;true&amp;lt;/AllowRemove&amp;gt;
  &amp;lt;AllowZoneChange&amp;gt;true&amp;lt;/AllowZoneChange&amp;gt;
  &amp;lt;AllowMinimize&amp;gt;true&amp;lt;/AllowMinimize&amp;gt;
  &amp;lt;AllowConnect&amp;gt;true&amp;lt;/AllowConnect&amp;gt;
  &amp;lt;AllowEdit&amp;gt;true&amp;lt;/AllowEdit&amp;gt;
  &amp;lt;AllowHide&amp;gt;true&amp;lt;/AllowHide&amp;gt;
  &amp;lt;IsVisible&amp;gt;true&amp;lt;/IsVisible&amp;gt;
  &amp;lt;DetailLink /&amp;gt;
  &amp;lt;HelpLink /&amp;gt;
  &amp;lt;HelpMode&amp;gt;Modeless&amp;lt;/HelpMode&amp;gt;
  &amp;lt;Dir&amp;gt;Default&amp;lt;/Dir&amp;gt;
  &amp;lt;PartImageSmall /&amp;gt;
  &amp;lt;MissingAssembly&amp;gt;Cannot import this Web Part.&amp;lt;/MissingAssembly&amp;gt;
  &amp;lt;PartImageLarge&amp;gt;/_layouts/images/mscontl.gif&amp;lt;/PartImageLarge&amp;gt;
  &amp;lt;IsIncludedFilter /&amp;gt;
  &amp;lt;Assembly&amp;gt;Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c&amp;lt;/Assembly&amp;gt;
  &amp;lt;TypeName&amp;gt;Microsoft.SharePoint.WebPartPages.ContentEditorWebPart&amp;lt;/TypeName&amp;gt;
  &amp;lt;ContentLink xmlns=&amp;quot;http://schemas.microsoft.com/WebPart/v2/ContentEditor&amp;quot; /&amp;gt;
  &amp;lt;Content xmlns=&amp;quot;http://schemas.microsoft.com/WebPart/v2/ContentEditor&amp;quot;&amp;gt;Hello world&amp;lt;/Content&amp;gt;
        &amp;lt;PartStorage xmlns=&amp;quot;http://schemas.microsoft.com/WebPart/v2/ContentEditor&amp;quot; /&amp;gt;
        &amp;lt;/WebPart&amp;gt;]]&amp;gt;&amp;lt;/AllUsersWebPart&amp;gt;
    &amp;lt;/File&amp;gt;
  &amp;lt;/Module&amp;gt;
&amp;lt;/Elements&amp;gt;&lt;/pre&gt;
&lt;blockquote&gt;&lt;p&gt;&lt;strong&gt;Important:&lt;/strong&gt; to provision a Web Part to a Web Part Page you will need a Web Part Page file. You can copy the default Web Part Page file from 14\TEMPLATE\SiteTemplates\sts\default.aspx.&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/Provisioning-Web-Parts-to-Wiki-Pages-in-_6B7A/01.jpg"&gt;&lt;img width="480" height="383" alt="Content Editor Web Part added to a Web Part Page in SharePoint 2010" src="http://blog.mastykarz.nl/images/Provisioning-Web-Parts-to-Wiki-Pages-in-_6B7A/01_thumb.jpg" border="0" style="background-image:none;border-bottom:0px;border-left:0px;padding-left:0px;padding-right:0px;display:inline;border-top:0px;border-right:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;As you can see adding Web Parts to Web Part Pages is fairly easy. The challenge begins however as soon as you start working with Wiki Pages.&lt;/p&gt;
&lt;h3&gt;Declaratively provisioning Web Part instances to Wiki Pages&lt;/h3&gt;
&lt;p&gt;One of the new features introduced with SharePoint 2010 was the concept of adding Web Parts in content. Before that we had to use Content Editor Web Parts to store content if we wanted to use Web Parts in between. With SharePoint 2010 we could just type rich content and insert Web Parts in between just as if we were adding images or tables.&lt;/p&gt;
&lt;p&gt;The Web Parts in content capability has been made available in Publishing Sites as well as Collaboration Sites. The only requirement with regards to Collaboration Sites is, that you have to be using Wiki Pages. A while ago I wrote &lt;a href="http://blog.mastykarz.nl/programmatically-adding-web-parts-rich-content-sharepoint-2010/"&gt;an article about how you can add Web Part instances to content&lt;/a&gt;. The approach I presented involved using custom code which unfortunately cannot be used from within Sandboxed Solutions as it relies on the SPLimitedWebPartManager class. However using the same information about how Web Parts in content work behind the scenes, we can alter the declarative approach used for Web Part Pages to add a Web Part to a Wiki Page. The following code snippet presents the Module modified to add the Content Editor Web Part to a Wiki Page:&lt;/p&gt;
&lt;pre class="brush: xml;"&gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;
&amp;lt;Elements xmlns=&amp;quot;http://schemas.microsoft.com/sharepoint/&amp;quot;&amp;gt;
  &amp;lt;Module Name=&amp;quot;HomePage&amp;quot;&amp;gt;
    &amp;lt;File Path=&amp;quot;HomePage\wkpstd.aspx&amp;quot; Url=&amp;quot;SitePages/Home.aspx&amp;quot;&amp;gt;
      &amp;lt;Property Name=&amp;quot;WikiField&amp;quot; Type=&amp;quot;string&amp;quot; Value=&amp;quot;
&amp;amp;lt;div class=&amp;amp;quot;ms-rtestate-read ms-rte-wpbox&amp;amp;quot; contentEditable=&amp;amp;quot;false&amp;amp;quot;&amp;amp;gt;&amp;amp;lt;div class=&amp;amp;quot;ms-rtestate-read 46113482-da36-45a5-bbac-e1e1771c19fa&amp;amp;quot; id=&amp;amp;quot;div_46113482-da36-45a5-bbac-e1e1771c19fa&amp;amp;quot;&amp;amp;gt;&amp;amp;lt;/div&amp;amp;gt;&amp;amp;lt;div style='display:none' id=&amp;amp;quot;vid_46113482-da36-45a5-bbac-e1e1771c19fa&amp;amp;quot;&amp;amp;gt;&amp;amp;lt;/div&amp;amp;gt;&amp;amp;lt;/div&amp;amp;gt;
      &amp;quot;/&amp;gt;
      &amp;lt;AllUsersWebPart WebPartOrder=&amp;quot;0&amp;quot; WebPartZoneID=&amp;quot;wpz&amp;quot; ID=&amp;quot;g_46113482_da36_45a5_bbac_e1e1771c19fa&amp;quot;&amp;gt;
        &amp;lt;![CDATA[&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;
&amp;lt;WebPart xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot; xmlns:xsd=&amp;quot;http://www.w3.org/2001/XMLSchema&amp;quot; xmlns=&amp;quot;http://schemas.microsoft.com/WebPart/v2&amp;quot;&amp;gt;
  &amp;lt;Title&amp;gt;Content Editor&amp;lt;/Title&amp;gt;
  &amp;lt;FrameType&amp;gt;Default&amp;lt;/FrameType&amp;gt;
  &amp;lt;Description&amp;gt;Allows authors to enter rich text content.&amp;lt;/Description&amp;gt;
  &amp;lt;IsIncluded&amp;gt;true&amp;lt;/IsIncluded&amp;gt;
  &amp;lt;ZoneID&amp;gt;Left&amp;lt;/ZoneID&amp;gt;
  &amp;lt;PartOrder&amp;gt;0&amp;lt;/PartOrder&amp;gt;
  &amp;lt;FrameState&amp;gt;Normal&amp;lt;/FrameState&amp;gt;
  &amp;lt;Height /&amp;gt;
  &amp;lt;Width /&amp;gt;
  &amp;lt;AllowRemove&amp;gt;true&amp;lt;/AllowRemove&amp;gt;
  &amp;lt;AllowZoneChange&amp;gt;true&amp;lt;/AllowZoneChange&amp;gt;
  &amp;lt;AllowMinimize&amp;gt;true&amp;lt;/AllowMinimize&amp;gt;
  &amp;lt;AllowConnect&amp;gt;true&amp;lt;/AllowConnect&amp;gt;
  &amp;lt;AllowEdit&amp;gt;true&amp;lt;/AllowEdit&amp;gt;
  &amp;lt;AllowHide&amp;gt;true&amp;lt;/AllowHide&amp;gt;
  &amp;lt;IsVisible&amp;gt;true&amp;lt;/IsVisible&amp;gt;
  &amp;lt;DetailLink /&amp;gt;
  &amp;lt;HelpLink /&amp;gt;
  &amp;lt;HelpMode&amp;gt;Modeless&amp;lt;/HelpMode&amp;gt;
  &amp;lt;Dir&amp;gt;Default&amp;lt;/Dir&amp;gt;
  &amp;lt;PartImageSmall /&amp;gt;
  &amp;lt;MissingAssembly&amp;gt;Cannot import this Web Part.&amp;lt;/MissingAssembly&amp;gt;
  &amp;lt;PartImageLarge&amp;gt;/_layouts/images/mscontl.gif&amp;lt;/PartImageLarge&amp;gt;
  &amp;lt;IsIncludedFilter /&amp;gt;
  &amp;lt;Assembly&amp;gt;Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c&amp;lt;/Assembly&amp;gt;
  &amp;lt;TypeName&amp;gt;Microsoft.SharePoint.WebPartPages.ContentEditorWebPart&amp;lt;/TypeName&amp;gt;
  &amp;lt;ContentLink xmlns=&amp;quot;http://schemas.microsoft.com/WebPart/v2/ContentEditor&amp;quot; /&amp;gt;
  &amp;lt;Content xmlns=&amp;quot;http://schemas.microsoft.com/WebPart/v2/ContentEditor&amp;quot;&amp;gt;​Hello world&amp;lt;/Content&amp;gt;
        &amp;lt;PartStorage xmlns=&amp;quot;http://schemas.microsoft.com/WebPart/v2/ContentEditor&amp;quot; /&amp;gt;
        &amp;lt;/WebPart&amp;gt;]]&amp;gt;&amp;lt;/AllUsersWebPart&amp;gt;
    &amp;lt;/File&amp;gt;
  &amp;lt;/Module&amp;gt;
&amp;lt;/Elements&amp;gt;&lt;/pre&gt;
&lt;blockquote&gt;&lt;p&gt;&lt;strong&gt;Important:&lt;/strong&gt; Note that the Wiki Page uses a different page file that can be copied from 14\TEMPLATE\DocumentTemplates\wkpstd.aspx&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/Provisioning-Web-Parts-to-Wiki-Pages-in-_6B7A/02.jpg"&gt;&lt;img width="480" height="370" alt="Content Editor Web Part added to a Wiki Page in SharePoint 2010" src="http://blog.mastykarz.nl/images/Provisioning-Web-Parts-to-Wiki-Pages-in-_6B7A/02_thumb.jpg" border="0" style="background-image:none;border-bottom:0px;border-left:0px;padding-left:0px;padding-right:0px;display:inline;border-top:0px;border-right:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;If you took a careful look at the code snippet you might have noticed that a few things have changed. First of all we changed the page’s URL to &lt;em&gt;SitePages/Home.aspx&lt;/em&gt; (line 4) so that it points to a Wiki Page instead of a Web Part Page. Next we added the &lt;em&gt;WikiField&lt;/em&gt; property (lines 5-7) which contains the content of the Wiki Page. Although the content is a little difficult to read it contains the HTML marker of Web Part added to content, which after decoding looks like this:&lt;/p&gt;
&lt;pre class="brush: xml;"&gt;&amp;lt;div class=&amp;quot;ms-rtestate-read ms-rte-wpbox&amp;quot; contenteditable=&amp;quot;false&amp;quot;&amp;gt;&amp;lt;div class=&amp;quot;ms-rtestate-notify  ms-rtestate-read 46113482-da36-45a5-bbac-e1e1771c19fa&amp;quot; id=&amp;quot;div_46113482-da36-45a5-bbac-e1e1771c19fa&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div id=&amp;quot;vid_46113482-da36-45a5-bbac-e1e1771c19fa&amp;quot; style=&amp;quot;display: none&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;/pre&gt;
&lt;p&gt;Next, to the &lt;em&gt;AllUsersWebPart&lt;/em&gt; tag we added the &lt;em&gt;ID&lt;/em&gt; attribute (line 8). Although &lt;a href="http://msdn.microsoft.com/en-us/library/ms446831.aspx?ocid=aff-n-we-loc--ITPRO40936&amp;amp;WT.mc_id=aff-n-we-loc--ITPRO40936"&gt;the SDK doesn’t explain what this attribute is for&lt;/a&gt;, it can be used to provision a Web Part with a predefined ID. The only requirement is, that all &lt;strong&gt;–&lt;/strong&gt; (dash) are replaced with &lt;strong&gt;_&lt;/strong&gt; (underscore) and the ID is prefixed with &lt;strong&gt;g_&lt;/strong&gt;. As you can see the Web Part’s ID corresponds to the ID used in the marker placed in the Wiki Page’s content.&lt;/p&gt;
&lt;h3&gt;Bonus: Declaratively Provisioning List View Web Parts to Wiki Pages&lt;/h3&gt;
&lt;p&gt;There are scenarios when you might need to provision a List View Web Part to a Wiki Page. The good news is that the required approach is not much different from provisioning a Content Editor Web Part or any other Web Part for that matter.&lt;/p&gt;
&lt;p&gt;If you’ve worked with declaratively provisioning List View Web Parts you know that in order to add a List View Web Part to a page you have to use the &lt;strong&gt;View&lt;/strong&gt; element. For example to add a List View Web Part for the Announements list available in a standard Team Site to a Web Part Page, you would use the following code:&lt;/p&gt;
&lt;pre class="brush: xml;"&gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;
&amp;lt;Elements xmlns=&amp;quot;http://schemas.microsoft.com/sharepoint/&amp;quot;&amp;gt;
  &amp;lt;Module Name=&amp;quot;HomePage&amp;quot;&amp;gt;
    &amp;lt;File Path=&amp;quot;HomePage\default.aspx&amp;quot; Url=&amp;quot;default.aspx&amp;quot;&amp;gt;
      &amp;lt;View List=&amp;quot;$Resources:core,lists_Folder;/$Resources:core,announce_Folder;&amp;quot; BaseViewID=&amp;quot;1&amp;quot; WebPartZoneID=&amp;quot;Left&amp;quot; WebPartOrder=&amp;quot;0&amp;quot; /&amp;gt;
    &amp;lt;/File&amp;gt;
  &amp;lt;/Module&amp;gt;
&amp;lt;/Elements&amp;gt;&lt;/pre&gt;
&lt;p&gt;Adding List View Web Parts to content is very similar to adding regular Web Parts. All you need to do is to change the value of the &lt;em&gt;WebPartZoneID&lt;/em&gt; attribute to &lt;strong&gt;wpz&lt;em&gt; &lt;/em&gt;&lt;/strong&gt;and add the &lt;em&gt;ID&lt;/em&gt; attribute to the &lt;em&gt;View&lt;/em&gt; element with a GUID specified exactly as if you would for any other Web Part that would be added in content, for example:&lt;/p&gt;
&lt;pre class="brush: xml;"&gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;
&amp;lt;Elements xmlns=&amp;quot;http://schemas.microsoft.com/sharepoint/&amp;quot;&amp;gt;
  &amp;lt;Module Name=&amp;quot;HomePage&amp;quot;&amp;gt;
    &amp;lt;File Path=&amp;quot;HomePage\wkpstd.aspx&amp;quot; Url=&amp;quot;SitePages/Home.aspx&amp;quot;&amp;gt;
      &amp;lt;Property Name=&amp;quot;WikiField&amp;quot; Type=&amp;quot;string&amp;quot; Value=&amp;quot;
&amp;amp;lt;div class=&amp;amp;quot;ms-rtestate-read ms-rte-wpbox&amp;amp;quot; contentEditable=&amp;amp;quot;false&amp;amp;quot;&amp;amp;gt;&amp;amp;lt;div class=&amp;amp;quot;ms-rtestate-read 46113482-da36-45a5-bbac-e1e1771c19fa&amp;amp;quot; id=&amp;amp;quot;div_46113482-da36-45a5-bbac-e1e1771c19fa&amp;amp;quot;&amp;amp;gt;&amp;amp;lt;/div&amp;amp;gt;&amp;amp;lt;div style='display:none' id=&amp;amp;quot;vid_46113482-da36-45a5-bbac-e1e1771c19fa&amp;amp;quot;&amp;amp;gt;&amp;amp;lt;/div&amp;amp;gt;&amp;amp;lt;/div&amp;amp;gt;
      &amp;quot;/&amp;gt;
      &amp;lt;View List=&amp;quot;$Resources:core,lists_Folder;/$Resources:core,announce_Folder;&amp;quot; BaseViewID=&amp;quot;1&amp;quot; WebPartZoneID=&amp;quot;wpz&amp;quot; WebPartOrder=&amp;quot;4&amp;quot; ID=&amp;quot;g_46113482_da36_45a5_bbac_e1e1771c19fa&amp;quot; /&amp;gt;
    &amp;lt;/File&amp;gt;
&amp;lt;/Module&amp;gt;
&amp;lt;/Elements&amp;gt;&lt;/pre&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/Provisioning-Web-Parts-to-Wiki-Pages-in-_6B7A/03.jpg"&gt;&lt;img width="480" height="309" alt="The Announcements List View Web Part added to a Team Site" src="http://blog.mastykarz.nl/images/Provisioning-Web-Parts-to-Wiki-Pages-in-_6B7A/03_thumb.jpg" border="0" style="background-image:none;border-bottom:0px;border-left:0px;padding-left:0px;padding-right:0px;display:inline;border-top:0px;border-right:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Summary&lt;/h2&gt;
&lt;p&gt;Sandboxed Solutions offer great power and flexibility for extending the SharePoint platform with custom functionality. The price of this empowerment is limited access to the SharePoint API and the .NET Framework. One of the common tasks which is affected is provisioning Web Part instances to pages. Although the programmatic approach is not available to SharePoint developers, the declarative way is a good alternative.&lt;/p&gt;
&lt;p&gt;Originally posted at &lt;a href="http://blog.mastykarz.nl/inconvenient-provisioning-web-parts-wiki-pages-sandboxed-solutions/?utm_source=mavention&amp;amp;utm_medium=preview&amp;amp;utm_campaign=Mavention Blog"&gt;http://blog.mastykarz.nl/inconvenient-provisioning-web-parts-wiki-pages-sandboxed-solutions/&lt;/a&gt;&lt;/p&gt;</description><pubDate>Sun, 05 Feb 2012 14:13:57 GMT</pubDate></item><item><title>Kennisnet voor Nederlandse Zorgautoriteit online</title><link>http://www.mavention.nl/nieuws/Pages/kennisnet-nederlandse-zorgautoriteit-nza-online.aspx</link><description>&lt;p&gt;&lt;span&gt;&lt;span&gt;&lt;strong&gt;Het interne kennisplatform van de Nederlandse Zorgautoriteit (NZa) is live gegaan: Kennisnet. Het doel van Kennisnet is het delen en verspreiden van kennis over verschillende aspecten van zorgonderwerpen en zorgmarkten. Kennisnet is voor iedereen binnen NZa toegankelijk.&lt;/strong&gt;&lt;/span&gt;&lt;/span&gt;&lt;span&gt;&lt;strong&gt;&lt;strong&gt; &lt;/strong&gt;&lt;br /&gt;&lt;/strong&gt;&lt;br /&gt;Binnen Kennisnet hebben de NZa-medewerkers een eigen profielpagina die zij zelf invullen en aanvullen met kennis, expertise en ervaring. Binnen deze profielpagina’s kan naar collega’s gezocht worden met bepaalde kennis of ervaring. Daarnaast is een keur aan achtergrondinformatie opgenomen, in zogeheten Wiki’s. NZa-medewerkers werken samen aan een bepaald zorgonderwerp en houden de kennis actueel. Bovendien kan via de digitale werkruimten een groepje collega’s met elkaar contact houden, vragen en dilemma's voorleggen, discussies voeren over actuele ontwikkelingen en documenten uitwisselen.&lt;br /&gt;&lt;br /&gt;Als kennisintensieve organisatie heeft NZa behoefte aan een&lt;span&gt;  &lt;/span&gt;eenvoudig en efficiënt platform voor het uitwisselen van kennis en ervaring en een platform waar collega’s makkelijk kunnen samenwerken. Het door Mavention ontwikkelde Kennisnet biedt dit platform.&lt;br /&gt;&lt;br /&gt;Kennisnet is een onderdeel van het NZa-project professionalisering informatiestromen.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;Meer informatie is te vinden op de &lt;a href="/klantcases/Pages/NZa%20Kennisnet.aspx"&gt;referentiepagina&lt;/a&gt; van het project Kennisnet voor de NZa.&lt;/p&gt;</description><pubDate>Wed, 01 Feb 2012 10:30:43 GMT</pubDate></item><item><title>Easier using widgets in SharePoint 2010 with the Mavention Widget Web Part</title><link>http://www.mavention.nl/blog/Pages/easier-widgets-sharepoint-2010-mavention-widget-web-part.aspx</link><description>&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/inconvenient-widgets-sharepoint-end-users/"&gt;In my previous article I explained why using widgets in SharePoint 2010 is inconvenient and showed what you can do to make it easier using the standard functionality&lt;/a&gt;. In this article I’ll show you how you can simplify working with widgets even further using the Mavention Widget Sandboxed Web Part.&lt;/p&gt;
&lt;h2&gt;Mavention Widget Web Part&lt;/h2&gt;
&lt;p&gt;The Mavention Widget Web Part is a Sandboxed Web Part which allows you to include in the page any snippet of HTML without any restrictions. Although from the functionality point of view this Web Part doesn’t seem like much, it’s offering you a lot of flexibility and simplifies the maintenance of your pages.&lt;/p&gt;
&lt;p&gt;In order to use the Mavention Widget Web Part you have to activate the Mavention Widget Web Parts Package first. Since it is a Sandboxed Solution you can do it by opening the &lt;strong&gt;Site Settings&lt;/strong&gt; and navigating to the &lt;strong&gt;Solution Gallery&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/01.jpg"&gt;&lt;img width="473" height="427" alt="Link to the Solution Gallery highlighted on the Site Settings page" src="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/01_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;After uploading and activating the Mavention Widget Web Parts Package the Mavention Widget Web Parts Feature is installed. Because it’s a Site Collection-scoped Feature it is also automatically activated allowing you to directly start with including widgets on your pages.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/02.jpg"&gt;&lt;img width="480" height="58" alt="The Mavention Widget Web Parts Feature activated" src="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/02_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;After activating the Solution Package navigate to the page where you would like to insert a widget, edit the page and from the &lt;strong&gt;Insert&lt;/strong&gt; tab click the &lt;strong&gt;Web Part&lt;/strong&gt; button.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/03.jpg"&gt;&lt;img width="480" height="349" alt="The Insert Web Part button highlighted in the Ribbon" src="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/03_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;From the Categories list choose &lt;strong&gt;Mavention Web Parts&lt;/strong&gt; (1), select the &lt;strong&gt;Widget Web Part&lt;/strong&gt; (2) and click the &lt;strong&gt;Add&lt;/strong&gt; button (3) to add the Web Part.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/04.jpg"&gt;&lt;img width="480" height="241" alt="Web Part Gallery opened on a page in SharePoint 2010" src="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/04_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;After adding the Web Part, edit its properties and from the &lt;strong&gt;Widget Web Part&lt;/strong&gt; section click the &lt;strong&gt;Edit…&lt;/strong&gt; button.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/05.jpg"&gt;&lt;img width="480" height="212" alt="The Edit Widget contents button highlighted in the Widget Web Part properties pane" src="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/05_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Next, in the dialog window, paste the contents of your widget and confirm changes by clicking the &lt;strong&gt;OK&lt;/strong&gt; button.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/06.jpg"&gt;&lt;img width="437" height="427" alt="twitter search widget pasted in the Widget Web Part" src="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/06_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;After you confirm changes the widget will appear in the Web Part.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/07.jpg"&gt;&lt;img width="332" height="427" alt="twitter search widget displayed in the Widget Web Part" src="http://blog.mastykarz.nl/images/08a78ee4d651_BF78/07_thumb.jpg" border="0" style="background-image:none;border-right-width:0px;padding-left:0px;padding-right:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Editing the widget is just as easy as adding it. All you need to do is to open the Widget Web Part’s properties, click the &lt;strong&gt;Edit…&lt;/strong&gt; button and you will see the widget’s code just as you pasted it.&lt;/p&gt;
&lt;p&gt;Download: &lt;a href="http://blog.mastykarz.nl/go/d-mavention_widgetwebparts/"&gt;Mavention Widget Web Part&lt;/a&gt; (5KB, Sandboxed WSP)&lt;/p&gt;
&lt;p&gt;Originally posted at &lt;a href="http://blog.mastykarz.nl/easier-widgets-sharepoint-2010-mavention-widget-web-part/?utm_source=mavention&amp;amp;utm_medium=preview&amp;amp;utm_campaign=Mavention Blog"&gt;http://blog.mastykarz.nl/easier-widgets-sharepoint-2010-mavention-widget-web-part/&lt;/a&gt;&lt;/p&gt;</description><pubDate>Fri, 27 Jan 2012 15:03:18 GMT</pubDate></item><item><title>Deploying solutions with Language Packs with PowerShell</title><link>http://www.mavention.nl/blog/Pages/deploying-solutions-with-language-packs-with-powershell.aspx</link><description>&lt;p&gt;In &lt;a href="http://blog.octavie.nl/index.php/2011/06/10/deploying-your-solution-with-powershell-part-1/" target="_blank"&gt;previous post(s)&lt;/a&gt; I described deploying your solutions with PowerShell. Lately I encountered the situation I had to deploy a solution language pack. This is a regular WSP file with the same Solution ID as the original solution, but containing localization resources for specific languages. The purpose of solution language packs is to add localization for additional languages after the original solution package has already been distributed without having to upgrade the original solution package. I suggest you read this MSDN article about &lt;a href="http://msdn.microsoft.com/en-us/library/gg576899.aspx" target="_blank"&gt;Working with Language Pack Farm Solutions&lt;/a&gt;.&lt;/p&gt;
&lt;h3&gt;Deployment&lt;/h3&gt;
&lt;p&gt;For deploying these solution language packs the same PowerShell cmdlets can be used: Add-SPSolution and Install-SPSolution. However, this time the –Language parameter must be used. Keep in mind that the original solution is deployed first.&lt;/p&gt;
&lt;h3&gt;Removal&lt;/h3&gt;
&lt;p&gt;For removing these solution language packs the same PowerShell cmdlets can be used: Remove-SPSolution and Uninstall-SPSolution. Again, the –Language parameter must be used. Also, the original solution is still present in the farm.&lt;/p&gt;
&lt;h3&gt;Extending the script&lt;/h3&gt;
&lt;p&gt;So, how can we fit this deployment and removal in our &lt;a href="http://blog.octavie.nl/index.php/2011/06/22/deploying-your-solution-with-powershell-part-2/" target="_blank"&gt;existing script&lt;/a&gt; Solutions.ps1?&lt;/p&gt;
&lt;p&gt;First of all, we need to tell our script we’re dealing with a solution language pack. I have created a Solution.xml file with solutions to deploy, remove or update (I kept it simple):&lt;/p&gt;
&lt;div&gt;&lt;div class="syntaxhighlighter  xml ie" id="highlighter_497328"&gt;&lt;table border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="gutter"&gt;&lt;div class="line number1 index0 alt2"&gt;1&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;2&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;3&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;4&lt;/div&gt;&lt;/td&gt;
&lt;td class="code"&gt;&lt;div class="container"&gt;&lt;div class="line number1 index0 alt2"&gt;&lt;code class="xml plain"&gt;&amp;lt;&lt;/code&gt;&lt;code class="xml keyword"&gt;Solutions&lt;/code&gt;&lt;code class="xml plain"&gt;&amp;gt;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;&lt;code class="xml spaces"&gt;  &lt;/code&gt;&lt;code class="xml plain"&gt;&amp;lt;&lt;/code&gt;&lt;code class="xml keyword"&gt;Solution&lt;/code&gt; &lt;code class="xml color1"&gt;file&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;..\SharePointLearningKit.wsp&amp;quot;&lt;/code&gt; &lt;code class="xml color1"&gt;deploy&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;TRUE&amp;quot;&lt;/code&gt; &lt;code class="xml color1"&gt;remove&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;TRUE&amp;quot;&lt;/code&gt; &lt;code class="xml color1"&gt;update&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;FALSE&amp;quot;&lt;/code&gt; &lt;code class="xml plain"&gt;/&amp;gt;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;&lt;code class="xml spaces"&gt;  &lt;/code&gt;&lt;code class="xml plain"&gt;&amp;lt;&lt;/code&gt;&lt;code class="xml keyword"&gt;Solution&lt;/code&gt; &lt;code class="xml color1"&gt;file&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;..\SharePointLearningKit-1043.wsp&amp;quot;&lt;/code&gt; &lt;code class="xml color1"&gt;deploy&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;TRUE&amp;quot;&lt;/code&gt; &lt;code class="xml color1"&gt;remove&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;TRUE&amp;quot;&lt;/code&gt; &lt;code class="xml color1"&gt;update&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;FALSE&amp;quot;&lt;/code&gt; &lt;code class="xml color1"&gt;lcid&lt;/code&gt;&lt;code class="xml plain"&gt;=&lt;/code&gt;&lt;code class="xml string"&gt;&amp;quot;1043&amp;quot;&lt;/code&gt; &lt;code class="xml plain"&gt;/&amp;gt;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;&lt;code class="xml plain"&gt;&amp;lt;/&lt;/code&gt;&lt;code class="xml keyword"&gt;Solutions&lt;/code&gt;&lt;code class="xml plain"&gt;&amp;gt;&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;The lcid attribute tells the script that it is a solution language pack and which language it is. Another important thing is that I have named the wsp file correctly: the same name as the original code solution and a suffix “-{lcid}”. I will use this in the scripts.&lt;/p&gt;
&lt;p&gt;Secondly, our deploy.ps1 (and also remove.ps1 and update.ps1) needs to be changed in order to use the Solutions.xml file.&lt;/p&gt;
&lt;div&gt;&lt;div class="syntaxhighlighter  ps ie" id="highlighter_955373"&gt;&lt;table border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="gutter"&gt;&lt;div class="line number1 index0 alt2"&gt;1&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;2&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;3&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;4&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;5&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;6&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;7&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;8&lt;/div&gt;
&lt;div class="line number9 index8 alt2"&gt;9&lt;/div&gt;
&lt;div class="line number10 index9 alt1"&gt;10&lt;/div&gt;
&lt;div class="line number11 index10 alt2"&gt;11&lt;/div&gt;
&lt;div class="line number12 index11 alt1"&gt;12&lt;/div&gt;
&lt;div class="line number13 index12 alt2"&gt;13&lt;/div&gt;
&lt;div class="line number14 index13 alt1"&gt;14&lt;/div&gt;
&lt;div class="line number15 index14 alt2"&gt;15&lt;/div&gt;
&lt;div class="line number16 index15 alt1"&gt;16&lt;/div&gt;
&lt;div class="line number17 index16 alt2"&gt;17&lt;/div&gt;&lt;/td&gt;
&lt;td class="code"&gt;&lt;div class="container"&gt;&lt;div class="line number1 index0 alt2"&gt;&lt;code class="ps value"&gt;$deployConfig&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps keyword"&gt;Get-Content&lt;/code&gt; &lt;code class="ps plain"&gt;Solutions.xml&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt; &lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;&lt;code class="ps keyword"&gt;foreach&lt;/code&gt;&lt;code class="ps plain"&gt;( &lt;/code&gt;&lt;code class="ps value"&gt;$solution&lt;/code&gt; &lt;code class="ps plain"&gt;in &lt;/code&gt;&lt;code class="ps value"&gt;$deployConfig&lt;/code&gt;&lt;code class="ps plain"&gt;.Solutions.Solution )&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$solution&lt;/code&gt;&lt;code class="ps plain"&gt;.deploy.ToUpper().Equals(&lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;TRUE&amp;quot;&lt;/code&gt;&lt;code class="ps plain"&gt;) )&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$solution&lt;/code&gt;&lt;code class="ps plain"&gt;.lcid )&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number9 index8 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps plain"&gt;.\solution.ps1 &lt;/code&gt;&lt;code class="ps keyword"&gt;-solution&lt;/code&gt; &lt;code class="ps value"&gt;$solution&lt;/code&gt;&lt;code class="ps plain"&gt;.file &lt;/code&gt;&lt;code class="ps keyword"&gt;-deploy&lt;/code&gt; &lt;code class="ps keyword"&gt;-url&lt;/code&gt; &lt;code class="ps value"&gt;$url&lt;/code&gt; &lt;code class="ps keyword"&gt;-language&lt;/code&gt; &lt;code class="ps value"&gt;$solution&lt;/code&gt;&lt;code class="ps plain"&gt;.lcid&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number10 index9 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number11 index10 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number12 index11 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number13 index12 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps plain"&gt;.\solution.ps1 &lt;/code&gt;&lt;code class="ps keyword"&gt;-solution&lt;/code&gt; &lt;code class="ps value"&gt;$solution&lt;/code&gt;&lt;code class="ps plain"&gt;.file &lt;/code&gt;&lt;code class="ps keyword"&gt;-deploy&lt;/code&gt; &lt;code class="ps keyword"&gt;-url&lt;/code&gt; &lt;code class="ps value"&gt;$url&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number14 index13 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number15 index14 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number16 index15 alt1"&gt; &lt;/div&gt;
&lt;div class="line number17 index16 alt2"&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;When the solution configuration item contains a lcid attribute it calls the solution.ps1 script with the language parameter provided with the lcid value. &lt;/p&gt;
&lt;p&gt;Third and final step is to change the solution.ps1 script to actually deploy (or remove or update) the solution language pack. As just mentioned the solution.ps1 script has an additional parameter Language:&lt;/p&gt;
&lt;div&gt;&lt;div class="syntaxhighlighter  ps ie" id="highlighter_346592"&gt;&lt;table border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="gutter"&gt;&lt;div class="line number1 index0 alt2"&gt;1&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;2&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;3&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;4&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;5&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;6&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;7&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;8&lt;/div&gt;&lt;/td&gt;
&lt;td class="code"&gt;&lt;div class="container"&gt;&lt;div class="line number1 index0 alt2"&gt;&lt;code class="ps plain"&gt;param(&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;[string]&lt;/code&gt;&lt;code class="ps value"&gt;$solution&lt;/code&gt;&lt;code class="ps plain"&gt;,&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;[string]&lt;/code&gt;&lt;code class="ps value"&gt;$url&lt;/code&gt;&lt;code class="ps plain"&gt;,&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;[switch]&lt;/code&gt;&lt;code class="ps value"&gt;$deploy&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$false&lt;/code&gt;&lt;code class="ps plain"&gt;,&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;[switch]&lt;/code&gt;&lt;code class="ps value"&gt;$remove&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$false&lt;/code&gt;&lt;code class="ps plain"&gt;,&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;[switch]&lt;/code&gt;&lt;code class="ps value"&gt;$update&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$false&lt;/code&gt;&lt;code class="ps plain"&gt;,&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;[int]&lt;/code&gt;&lt;code class="ps value"&gt;$language&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;&lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;Then if $language is provided (the actual value will be greater then 0), we are dealing with a solution language pack and we need to know the name of the original solution.&lt;/p&gt;
&lt;div&gt;&lt;div class="syntaxhighlighter  ps ie" id="highlighter_218817"&gt;&lt;table border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="gutter"&gt;&lt;div class="line number1 index0 alt2"&gt;1&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;2&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;3&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;4&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;5&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;6&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;7&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;8&lt;/div&gt;
&lt;div class="line number9 index8 alt2"&gt;9&lt;/div&gt;
&lt;div class="line number10 index9 alt1"&gt;10&lt;/div&gt;&lt;/td&gt;
&lt;td class="code"&gt;&lt;div class="container"&gt;&lt;div class="line number1 index0 alt2"&gt;&lt;code class="ps comments"&gt;# locate the solution file:&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;&lt;code class="ps value"&gt;$solutionFile&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps keyword"&gt;Get-ChildItem&lt;/code&gt; &lt;code class="ps value"&gt;$solution&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;&lt;code class="ps comments"&gt;# get the solution Name&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;&lt;code class="ps value"&gt;$solutionName&lt;/code&gt; &lt;code class="ps plain"&gt;= [System.IO.Path]::GetFilename(&lt;/code&gt;&lt;code class="ps value"&gt;$solutionFile&lt;/code&gt;&lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt; &lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$language&lt;/code&gt;&lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps comments"&gt;#solutionCoreName is the name of the original solution package&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number9 index8 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps value"&gt;$solutionCoreName&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$solutionName&lt;/code&gt;&lt;code class="ps plain"&gt;.Replace( &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;-$language&amp;quot;&lt;/code&gt;&lt;code class="ps plain"&gt;, &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;&amp;quot;&lt;/code&gt; &lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number10 index9 alt1"&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;For deployment, the script looks like this:&lt;/p&gt;
&lt;div&gt;&lt;div class="syntaxhighlighter  ps ie" id="highlighter_640673"&gt;&lt;table border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="gutter"&gt;&lt;div class="line number1 index0 alt2"&gt;1&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;2&lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;3&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;4&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;5&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;6&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;7&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;8&lt;/div&gt;
&lt;div class="line number9 index8 alt2"&gt;9&lt;/div&gt;
&lt;div class="line number10 index9 alt1"&gt;10&lt;/div&gt;
&lt;div class="line number11 index10 alt2"&gt;11&lt;/div&gt;
&lt;div class="line number12 index11 alt1"&gt;12&lt;/div&gt;
&lt;div class="line number13 index12 alt2"&gt;13&lt;/div&gt;
&lt;div class="line number14 index13 alt1"&gt;14&lt;/div&gt;
&lt;div class="line number15 index14 alt2"&gt;15&lt;/div&gt;
&lt;div class="line number16 index15 alt1"&gt;16&lt;/div&gt;
&lt;div class="line number17 index16 alt2"&gt;17&lt;/div&gt;
&lt;div class="line number18 index17 alt1"&gt;18&lt;/div&gt;
&lt;div class="line number19 index18 alt2"&gt;19&lt;/div&gt;
&lt;div class="line number20 index19 alt1"&gt;20&lt;/div&gt;
&lt;div class="line number21 index20 alt2"&gt;21&lt;/div&gt;
&lt;div class="line number22 index21 alt1"&gt;22&lt;/div&gt;
&lt;div class="line number23 index22 alt2"&gt;23&lt;/div&gt;
&lt;div class="line number24 index23 alt1"&gt;24&lt;/div&gt;
&lt;div class="line number25 index24 alt2"&gt;25&lt;/div&gt;
&lt;div class="line number26 index25 alt1"&gt;26&lt;/div&gt;
&lt;div class="line number27 index26 alt2"&gt;27&lt;/div&gt;
&lt;div class="line number28 index27 alt1"&gt;28&lt;/div&gt;
&lt;div class="line number29 index28 alt2"&gt;29&lt;/div&gt;
&lt;div class="line number30 index29 alt1"&gt;30&lt;/div&gt;
&lt;div class="line number31 index30 alt2"&gt;31&lt;/div&gt;
&lt;div class="line number32 index31 alt1"&gt;32&lt;/div&gt;
&lt;div class="line number33 index32 alt2"&gt;33&lt;/div&gt;
&lt;div class="line number34 index33 alt1"&gt;34&lt;/div&gt;
&lt;div class="line number35 index34 alt2"&gt;35&lt;/div&gt;
&lt;div class="line number36 index35 alt1"&gt;36&lt;/div&gt;
&lt;div class="line number37 index36 alt2"&gt;37&lt;/div&gt;
&lt;div class="line number38 index37 alt1"&gt;38&lt;/div&gt;
&lt;div class="line number39 index38 alt2"&gt;39&lt;/div&gt;
&lt;div class="line number40 index39 alt1"&gt;40&lt;/div&gt;
&lt;div class="line number41 index40 alt2"&gt;41&lt;/div&gt;
&lt;div class="line number42 index41 alt1"&gt;42&lt;/div&gt;
&lt;div class="line number43 index42 alt2"&gt;43&lt;/div&gt;
&lt;div class="line number44 index43 alt1"&gt;44&lt;/div&gt;
&lt;div class="line number45 index44 alt2"&gt;45&lt;/div&gt;
&lt;div class="line number46 index45 alt1"&gt;46&lt;/div&gt;
&lt;div class="line number47 index46 alt2"&gt;47&lt;/div&gt;
&lt;div class="line number48 index47 alt1"&gt;48&lt;/div&gt;
&lt;div class="line number49 index48 alt2"&gt;49&lt;/div&gt;
&lt;div class="line number50 index49 alt1"&gt;50&lt;/div&gt;
&lt;div class="line number51 index50 alt2"&gt;51&lt;/div&gt;
&lt;div class="line number52 index51 alt1"&gt;52&lt;/div&gt;
&lt;div class="line number53 index52 alt2"&gt;53&lt;/div&gt;
&lt;div class="line number54 index53 alt1"&gt;54&lt;/div&gt;
&lt;div class="line number55 index54 alt2"&gt;55&lt;/div&gt;
&lt;div class="line number56 index55 alt1"&gt;56&lt;/div&gt;
&lt;div class="line number57 index56 alt2"&gt;57&lt;/div&gt;
&lt;div class="line number58 index57 alt1"&gt;58&lt;/div&gt;
&lt;div class="line number59 index58 alt2"&gt;59&lt;/div&gt;
&lt;div class="line number60 index59 alt1"&gt;60&lt;/div&gt;
&lt;div class="line number61 index60 alt2"&gt;61&lt;/div&gt;
&lt;div class="line number62 index61 alt1"&gt;62&lt;/div&gt;
&lt;div class="line number63 index62 alt2"&gt;63&lt;/div&gt;
&lt;div class="line number64 index63 alt1"&gt;64&lt;/div&gt;
&lt;div class="line number65 index64 alt2"&gt;65&lt;/div&gt;
&lt;div class="line number66 index65 alt1"&gt;66&lt;/div&gt;
&lt;div class="line number67 index66 alt2"&gt;67&lt;/div&gt;
&lt;div class="line number68 index67 alt1"&gt;68&lt;/div&gt;
&lt;div class="line number69 index68 alt2"&gt;69&lt;/div&gt;
&lt;div class="line number70 index69 alt1"&gt;70&lt;/div&gt;
&lt;div class="line number71 index70 alt2"&gt;71&lt;/div&gt;
&lt;div class="line number72 index71 alt1"&gt;72&lt;/div&gt;
&lt;div class="line number73 index72 alt2"&gt;73&lt;/div&gt;
&lt;div class="line number74 index73 alt1"&gt;74&lt;/div&gt;
&lt;div class="line number75 index74 alt2"&gt;75&lt;/div&gt;
&lt;div class="line number76 index75 alt1"&gt;76&lt;/div&gt;
&lt;div class="line number77 index76 alt2"&gt;77&lt;/div&gt;
&lt;div class="line number78 index77 alt1"&gt;78&lt;/div&gt;
&lt;div class="line number79 index78 alt2"&gt;79&lt;/div&gt;
&lt;div class="line number80 index79 alt1"&gt;80&lt;/div&gt;
&lt;div class="line number81 index80 alt2"&gt;81&lt;/div&gt;
&lt;div class="line number82 index81 alt1"&gt;82&lt;/div&gt;
&lt;div class="line number83 index82 alt2"&gt;83&lt;/div&gt;
&lt;div class="line number84 index83 alt1"&gt;84&lt;/div&gt;
&lt;div class="line number85 index84 alt2"&gt;85&lt;/div&gt;
&lt;div class="line number86 index85 alt1"&gt;86&lt;/div&gt;
&lt;div class="line number87 index86 alt2"&gt;87&lt;/div&gt;
&lt;div class="line number88 index87 alt1"&gt;88&lt;/div&gt;
&lt;div class="line number89 index88 alt2"&gt;89&lt;/div&gt;&lt;/td&gt;
&lt;td class="code"&gt;&lt;div class="container"&gt;&lt;div class="line number1 index0 alt2"&gt;&lt;code class="ps plain"&gt;if(&lt;/code&gt;&lt;code class="ps value"&gt;$deploy&lt;/code&gt;&lt;code class="ps plain"&gt;){&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt; &lt;/div&gt;
&lt;div class="line number3 index2 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps string"&gt;&amp;quot;&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number4 index3 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Installing &amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number5 index4 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Green &lt;/code&gt;&lt;code class="ps value"&gt;$solutionName&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number6 index5 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number7 index6 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number8 index7 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Green &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;($language)&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number9 index8 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number10 index9 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number11 index10 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number12 index11 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps string"&gt;&amp;quot;&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number13 index12 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number14 index13 alt1"&gt; &lt;/div&gt;
&lt;div class="line number15 index14 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number16 index15 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number17 index16 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= Get&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps value"&gt;$solutionCoreName&lt;/code&gt; &lt;code class="ps keyword"&gt;-ErrorAction&lt;/code&gt; &lt;code class="ps plain"&gt;SilentlyContinue&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number18 index17 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;.LanguagePacks | &lt;/code&gt;&lt;code class="ps keyword"&gt;where-object&lt;/code&gt; &lt;code class="ps plain"&gt;{ $_.LocaleId &lt;/code&gt;&lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number19 index18 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number20 index19 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number21 index20 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number22 index21 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= Get&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps value"&gt;$solutionName&lt;/code&gt; &lt;code class="ps keyword"&gt;-ErrorAction&lt;/code&gt; &lt;code class="ps plain"&gt;SilentlyContinue&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number23 index22 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number24 index23 alt1"&gt; &lt;/div&gt;
&lt;div class="line number25 index24 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if (&lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number26 index25 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number27 index26 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;$solutionName already installed in this farm&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number28 index27 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number29 index28 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number30 index29 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number31 index30 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Adding to the farm&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number32 index31 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number33 index32 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number34 index33 alt1"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot; with langauge $language&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number35 index34 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= Add&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps value"&gt;$solutionFile&lt;/code&gt; &lt;code class="ps keyword"&gt;-Language&lt;/code&gt; &lt;code class="ps value"&gt;$language&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number36 index35 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number37 index36 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number38 index37 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number39 index38 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= Add&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps value"&gt;$solutionFile&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number40 index39 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number41 index40 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Green &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot; DONE&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number42 index41 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number43 index42 alt2"&gt; &lt;/div&gt;
&lt;div class="line number44 index43 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number45 index44 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number46 index45 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;.LanguagePacks | &lt;/code&gt;&lt;code class="ps keyword"&gt;where-object&lt;/code&gt; &lt;code class="ps plain"&gt;{ $_.LocaleId &lt;/code&gt;&lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number47 index46 alt2"&gt; &lt;/div&gt;
&lt;div class="line number48 index47 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;if ( &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;.ContainsWebApplicationResource ) {&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number49 index48 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Deploying to $url&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number50 index49 alt1"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps plain"&gt;Install&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps keyword"&gt;-Identity&lt;/code&gt; &lt;code class="ps value"&gt;$solutionCoreName&lt;/code&gt; &lt;code class="ps keyword"&gt;-GacDeployment&lt;/code&gt; &lt;code class="ps keyword"&gt;-CasPolicies&lt;/code&gt; &lt;code class="ps keyword"&gt;-Language&lt;/code&gt; &lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps keyword"&gt;-Webapplication&lt;/code&gt; &lt;code class="ps value"&gt;$url&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number51 index50 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number52 index51 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;else {&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number53 index52 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Deploying&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number54 index53 alt1"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps plain"&gt;Install&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps keyword"&gt;-Identity&lt;/code&gt; &lt;code class="ps value"&gt;$solutionCoreName&lt;/code&gt; &lt;code class="ps keyword"&gt;-GacDeployment&lt;/code&gt; &lt;code class="ps keyword"&gt;-CasPolicies&lt;/code&gt; &lt;code class="ps keyword"&gt;-Language&lt;/code&gt; &lt;code class="ps value"&gt;$language&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number55 index54 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number56 index55 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number57 index56 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number58 index57 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number59 index58 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;if ( &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;.ContainsWebApplicationResource ) {&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number60 index59 alt1"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Deploying to $url&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number61 index60 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps plain"&gt;Install&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps keyword"&gt;-Identity&lt;/code&gt; &lt;code class="ps value"&gt;$solutionName&lt;/code&gt; &lt;code class="ps keyword"&gt;-GacDeployment&lt;/code&gt; &lt;code class="ps keyword"&gt;-CasPolicies&lt;/code&gt; &lt;code class="ps keyword"&gt;-Webapplication&lt;/code&gt; &lt;code class="ps value"&gt;$url&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number62 index61 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number63 index62 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;else {&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number64 index63 alt1"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;Deploying&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number65 index64 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps plain"&gt;Install&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps keyword"&gt;-Identity&lt;/code&gt; &lt;code class="ps value"&gt;$solutionName&lt;/code&gt; &lt;code class="ps keyword"&gt;-GacDeployment&lt;/code&gt; &lt;code class="ps keyword"&gt;-CasPolicies&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number66 index65 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number67 index66 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number68 index67 alt1"&gt; &lt;/div&gt;
&lt;div class="line number69 index68 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if( &lt;/code&gt;&lt;code class="ps value"&gt;$language&lt;/code&gt;&lt;code class="ps plain"&gt;)&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number70 index69 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number71 index70 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= Get&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps value"&gt;$solutionCoreName&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number72 index71 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;.LanguagePacks | &lt;/code&gt;&lt;code class="ps keyword"&gt;where-object&lt;/code&gt; &lt;code class="ps plain"&gt;{ $_.LocaleId &lt;/code&gt;&lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number73 index72 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number74 index73 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;else&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number75 index74 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;{&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number76 index75 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= Get&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps value"&gt;$solutionName&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number77 index76 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number78 index77 alt1"&gt; &lt;/div&gt;
&lt;div class="line number79 index78 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;if (&lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;.Deployed &lt;/code&gt;&lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$false&lt;/code&gt; &lt;code class="ps plain"&gt;) {&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number80 index79 alt1"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps value"&gt;$counter&lt;/code&gt; &lt;code class="ps plain"&gt;= 1&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number81 index80 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;while( (&lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;.JobExists &lt;/code&gt;&lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$true&lt;/code&gt; &lt;code class="ps plain"&gt;) &lt;/code&gt;&lt;code class="ps keyword"&gt;-and&lt;/code&gt; &lt;code class="ps plain"&gt;( &lt;/code&gt;&lt;code class="ps value"&gt;$counter&lt;/code&gt; &lt;code class="ps keyword"&gt;-lt&lt;/code&gt; &lt;code class="ps value"&gt;$safeguard&lt;/code&gt;  &lt;code class="ps plain"&gt;) ) {&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number82 index81 alt1"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;yellow &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot;.&amp;quot;&lt;/code&gt; &lt;code class="ps keyword"&gt;-NoNewline&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number83 index82 alt2"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps keyword"&gt;sleep&lt;/code&gt; &lt;code class="ps value"&gt;$sleeptime&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number84 index83 alt1"&gt;&lt;code class="ps spaces"&gt;            &lt;/code&gt;&lt;code class="ps value"&gt;$counter&lt;/code&gt;&lt;code class="ps plain"&gt;++&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number85 index84 alt2"&gt;&lt;code class="ps spaces"&gt;        &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number86 index85 alt1"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number87 index86 alt2"&gt;&lt;code class="ps spaces"&gt;    &lt;/code&gt;&lt;code class="ps keyword"&gt;Write-Host&lt;/code&gt; &lt;code class="ps keyword"&gt;-ForegroundColor&lt;/code&gt; &lt;code class="ps plain"&gt;Green &lt;/code&gt;&lt;code class="ps string"&gt;&amp;quot; DONE&amp;quot;&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number88 index87 alt1"&gt; &lt;/div&gt;
&lt;div class="line number89 index88 alt2"&gt;&lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;The interesting part is to get a reference to the solution language pack. First, get the original solution. It has a LanguagePacks property that returns the list of language packages associated with this solution. I want to have a reference to my language pack:&lt;/p&gt;
&lt;div&gt;&lt;div class="syntaxhighlighter  ps ie" id="highlighter_488392"&gt;&lt;table border="0" cellspacing="0" cellpadding="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="gutter"&gt;&lt;div class="line number1 index0 alt2"&gt;1&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;2&lt;/div&gt;&lt;/td&gt;
&lt;td class="code"&gt;&lt;div class="container"&gt;&lt;div class="line number1 index0 alt2"&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= Get&lt;/code&gt;&lt;code class="ps keyword"&gt;-SPSolution&lt;/code&gt; &lt;code class="ps value"&gt;$solutionCoreName&lt;/code&gt; &lt;code class="ps keyword"&gt;-ErrorAction&lt;/code&gt; &lt;code class="ps plain"&gt;SilentlyContinue&lt;/code&gt;&lt;/div&gt;
&lt;div class="line number2 index1 alt1"&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt; &lt;code class="ps plain"&gt;= &lt;/code&gt;&lt;code class="ps value"&gt;$sol&lt;/code&gt;&lt;code class="ps plain"&gt;.LanguagePacks | &lt;/code&gt;&lt;code class="ps keyword"&gt;where-object&lt;/code&gt; &lt;code class="ps plain"&gt;{ $_.LocaleId &lt;/code&gt;&lt;code class="ps keyword"&gt;-eq&lt;/code&gt; &lt;code class="ps value"&gt;$language&lt;/code&gt; &lt;code class="ps plain"&gt;}&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;If $sol is not null, I know the solution language pack is present in the farm. If it is null then I can add it and deploy it. &lt;/p&gt;
&lt;p&gt;Similar lines of code are for the remove and update scenario’s. I have all script files zipped and it can be downloaded &lt;a href="http://blog.octavie.nl/wp-content/uploads/2012/01/DeploymentScripts.zip"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Originally posted at &lt;a href="http://blog.octavie.nl/index.php/2012/01/27/deploying-solutions-with-language-packs-with-powershell/"&gt;http://blog.octavie.nl/index.php/2012/01/27/deploying-solutions-with-language-packs-with-powershell/&lt;/a&gt;&lt;/p&gt;</description><pubDate>Fri, 27 Jan 2012 13:36:18 GMT</pubDate></item></channel></rss>
