<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>The SharePoint Nomad</title>
	<atom:link href="http://sharepointnomad.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://sharepointnomad.wordpress.com</link>
	<description>Andre Galitsky&#039;s Blog on SharePoint administration, architecture, and knowledge management.</description>
	<lastBuildDate>Fri, 13 Jan 2012 21:38:19 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='sharepointnomad.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://1.gravatar.com/blavatar/bdf369582e52f099d86ebe1092f34ebb?s=96&#038;d=http%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>The SharePoint Nomad</title>
		<link>http://sharepointnomad.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://sharepointnomad.wordpress.com/osd.xml" title="The SharePoint Nomad" />
	<atom:link rel='hub' href='http://sharepointnomad.wordpress.com/?pushpress=hub'/>
		<item>
		<title>How to remove webparts from a SharePoint page programmatically using Powershell</title>
		<link>http://sharepointnomad.wordpress.com/2012/01/13/how-to-remove-webparts-from-a-sharepoint-page-programmatically-using-powershell/</link>
		<comments>http://sharepointnomad.wordpress.com/2012/01/13/how-to-remove-webparts-from-a-sharepoint-page-programmatically-using-powershell/#comments</comments>
		<pubDate>Fri, 13 Jan 2012 21:29:04 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[SharePoint administration]]></category>
		<category><![CDATA[powershell]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[sharepoint 2010]]></category>
		<category><![CDATA[webpart]]></category>
		<category><![CDATA[webpart remove]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=457</guid>
		<description><![CDATA[Let&#8217;s imagine this scenario: You need to remove a webpart from a SharePoint page in your farm.   Easy, right?  Go to the page, enter the Edit mode, click on the webpart, select Delete.  No problem!   Now what if you had 1000 sites to remove the webpart from?   Doing it by hand is impractical, so we&#8217;ll [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=457&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Let&#8217;s imagine this scenario:</p>
<p>You need to remove a webpart from a SharePoint page in your farm.   Easy, right?  Go to the page, enter the Edit mode, click on the webpart, select Delete.  No problem!   Now what if you had 1000 sites to remove the webpart from?   Doing it by hand is impractical, so we&#8217;ll need to use Powershell.</p>
<p>This will be a two step process:</p>
<p>Step 1, you need to run an inventory script which will generate a list of webparts and their GUIDs.</p>
<p>Step 2, you will use the webpart GUIDs from step 1 to run a removal script to remove the webparts.</p>
<p><strong>STEP 1. INVENTORY SCRIPT</strong></p>
<p>Execute the script below using the SharePoint 2010 Management Shell (PowerShell console).  This script does the following:</p>
<p>1. Iterate through all web applications in the farm and open every every site collection in each web app</p>
<p>2. For each site collection, access the homepage  &#8220;default.aspx&#8221; and capture a list of webparts on the page and their GUIDs.</p>
<p>3. Write the results to a file called &#8220;results.txt&#8221;, located in the same directory as the Powershell script.</p>
<p>The page name &#8220;default.aspx&#8221; is hard-coded in the script but can be easily changed to another page name or page path.</p>
<p>&nbsp;</p>
<p>Script source code</p>
<p><pre class="brush: vb; light: true; wrap-lines: false;">

[System.Reflection.Assembly]::Load(&quot;Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c&quot;) | out-null

$oContentService = [Microsoft.SharePoint.Administration.SPWebService]::ContentService;

[Microsoft.SharePoint.Administration.SPWebApplicationCollection]$waColl = $oContentService.WebApplications;

$log = &quot;.\results.txt&quot;    # output file name and path
$pagepath = &quot;/default.aspx&quot;    # change page name or page path here

&quot;Site URL; WebPart Title ; Webpart ID&quot; | out-file $log

$waColl1 = $waColl | where-object {$_.IsAdministrationWebApplication -eq $FALSE}

foreach ($wa in $waColl1)
{

foreach ($obj in $wa.Sites) 
{

write-host &quot;Processing: &quot; , $siteURL

$siteURL = $obj.URL

$site=new-object Microsoft.SharePoint.SPSite($siteURL)

$pageURL = $siteURL + $pagepath  
$web=$site.Openweb()   
$webpartmanager=$web.GetLimitedWebPartManager($pageURL,  [System.Web.UI.WebControls.WebParts.PersonalizationScope]::Shared)   
foreach ($webpart in $webpartmanager.WebParts)
{   
$siteURL + &quot;; &quot; + $webpart.Title + &quot; ;  &quot; + $webpart.ID | out-file $log -append   
}                           
}

}

write-host &quot;Finished.&quot;

</pre></p>
<p>&nbsp;</p>
<p><strong>STEP 2. WEBPART REMOVAL SCRIPT</strong></p>
<p>This script  will programmatically remove a webpart from a SharePoint page.  It takes as arguments the target site URL and the webpart GUID.   The script targets the main page &#8220;default.aspx&#8221; but can be changed to accept any other page name or page path.  </p>
<p>Notes:  Use the results from the INVENTORY SCRIPT to create a list of webparts and their GUIDs to remove.  Then build a script which calls out the WEBPART REMOVAL SCRIPT using the site URLs and webpart GUIDs as arguments.</p>
<p>The syntax is the following:</p>
<p>Execute the following command in SharePoint 2010 Management shell (Powershell console):</p>
<p>[WEBPART REMOVAL script file name]   [site URL]    [webpart GUID]</p>
<p>Example:</p>
<p>remove.ps1     <a href="http://mysharepointsite">http://mysharepointsite</a>     a1b83-8tyu-6897-oiy8</p>
<p>&nbsp;</p>
<p>Script source code</p>
<p><pre class="brush: vb; light: true; wrap-lines: false;">

[System.Reflection.Assembly]::Load(&quot;Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c&quot;) | out-null [System.Reflection.Assembly]::LoadWithPartialName(&quot;Microsoft.SharePoint.WebPartPages&quot;) [System.Reflection.Assembly]::LoadWithPartialName(&quot;Microsoft.SharePoint.Publishing&quot;)

$siteURL = $args[0]  # first argument: site URL

$webpartId = $args[1]   # second argument:  webpart GUID

$pagepath =  &quot;/default.aspx&quot;        # change page name or page path here

$pageURL = $siteURL + $pagepath

write-host &quot;Processing site: &quot;, $siteURL

Write-host &quot;Processing page: &quot; , $pageURL

write-host &quot;Processing webpart ID: &quot; , $webpartID

$site=new-object Microsoft.SharePoint.SPSite($siteURL)

$web=$site.Openweb()

$webpartmanager=$web.GetLimitedWebPartManager($pageURL, [System.Web.UI.WebControls.WebParts.PersonalizationScope]::Shared)

$webpartmanager.DeleteWebPart($webpartmanager.Webparts[$webpartId])

$web.Update()

$web.Dispose()

write-host &quot;Finished.&quot;

</pre></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/457/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/457/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/457/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=457&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2012/01/13/how-to-remove-webparts-from-a-sharepoint-page-programmatically-using-powershell/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
		<item>
		<title>Solving &#8220;The attempted operation is prohibited because it exceeds the list view threshold&#8221; error</title>
		<link>http://sharepointnomad.wordpress.com/2011/05/04/solving-the-attempted-operation-is-prohibited-because-it-exceeds-the-list-view-threshold-error/</link>
		<comments>http://sharepointnomad.wordpress.com/2011/05/04/solving-the-attempted-operation-is-prohibited-because-it-exceeds-the-list-view-threshold-error/#comments</comments>
		<pubDate>Thu, 05 May 2011 02:08:56 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[SharePoint administration]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=410</guid>
		<description><![CDATA[While working in SharePoint 2010, you may receive the following error: The attempted operation is prohibited because it exceeds the list view threshold enforced by the administrator. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=410&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>While working in SharePoint 2010, you may receive the following error:</p>
<p>The attempted operation is prohibited because it exceeds the list view threshold enforced by the administrator. <span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;"><strong>Description: </strong>An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.</p>
<p><strong>Exception Details: </strong>System.Runtime.InteropServices.COMException: &lt;nativehr&gt;0&#215;80004005&lt;/nativehr&gt;&lt;nativestack&gt;&lt;/nativestack&gt;The attempted operation is prohibited because it exceeds the list view threshold enforced by the administrator.</span></p>
<p><span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;">I got this error while trying to change the site URL in Site Settings.</span></p>
<p><span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;">The resolution to this error is:</span></p>
<p><span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;">1. Navigate to Central Administration.</span></p>
<p><span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;">2. Go to Application Management &gt; Manage Web Application and click on your web application to select it.</span></p>
<p><span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;">3. In the Ribbon, click on General Settings drop-down and choose &#8220;Resource Throttling&#8221;.</span></p>
<p><span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;">4. In the &#8220;List View Threshold&#8221;, increase the value (by a factor of 2, for example) and click OK.</span></p>
<p><span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;">5. Try to replicate the error.  If the error persists, increase the value again until the error goes away.</span></p>
<p><span style="font-family:Arial, Helvetica, Geneva, SunSans-Regular, sans-serif;"> </span></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/410/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/410/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/410/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/410/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/410/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/410/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/410/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/410/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/410/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/410/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/410/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/410/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/410/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/410/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=410&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2011/05/04/solving-the-attempted-operation-is-prohibited-because-it-exceeds-the-list-view-threshold-error/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
		<item>
		<title>Enabling full stack dumps (detailed error messages) on ASP.NET and SharePoint</title>
		<link>http://sharepointnomad.wordpress.com/2011/02/20/enabling-full-stack-dumps-on-asp-net-and-sharepoint-errors/</link>
		<comments>http://sharepointnomad.wordpress.com/2011/02/20/enabling-full-stack-dumps-on-asp-net-and-sharepoint-errors/#comments</comments>
		<pubDate>Mon, 21 Feb 2011 02:33:17 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[SharePoint administration]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=389</guid>
		<description><![CDATA[When an error occurs within SharePoint, the application by default will not display a detailed error message to the end user (this is done for security reasons).  When you&#8217;re actively configuring/developing your SharePoint platform, it is sometimes useful to display detailed error messages.   Here are the steps to do it: You must edit several “web.config” [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=389&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>When an error occurs within SharePoint, the application by default will not display a detailed error message to the end user (this is done for security reasons).  When you&#8217;re actively configuring/developing your SharePoint platform, it is sometimes useful to display detailed error messages.  </p>
<p>Here are the steps to do it:</p>
<p>You must edit several “web.config” files:</p>
<p>1. Each SharePoint web application you created will have its own “web.config”.  You can find these in the respective folders under “C:\inetpub\wwwroot\wss\VirtualDirectories”.</p>
<p>In the XML section &lt;system.web&gt; you have two changes to make:               </p>
<p>CHANGE #1:  <strong>&lt;customErrors mode=&#8221;Off&#8221; /&gt; </strong></p>
<p>( This is normally set to “On” so change it to “Off”)           </p>
<p>CHANGE #2:  <strong>&lt;compilation batch=&#8221;false&#8221; debug=&#8221;true&#8221;&gt; </strong></p>
<p>(The ‘debug’ attribute is normally set to “false” so change it to “true”)<br />
               <br />
In the XML section &lt;SharePoint&gt; you have a single change to make:<br />
CHANGE #3:  <strong>&lt;SafeMode MaxControls=&#8221;200&#8243; CallStack=&#8221;true&#8221;&#8230;&gt; </strong></p>
<p>(The ‘CallStack’ attribute is normally set to “false” so change it to “true”)</p>
<p>Remember, you must make these THREE changes in EACH of the web.config files found in the folder for each of your web applications!</p>
<p>2. You must also change the “web.config” that is global to SharePoint (ie:  applies to all web applications).  This file is located here:<br />
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\LAYOUTS\web.config</p>
<p>In the XML section &lt;system.web&gt; you have a single change to make:<br />
CHANGE #1:  <strong>&lt;customErrors mode=&#8221;Off&#8221; /&gt; </strong></p>
<p>(This is normally set to “On” so change it to “Off”)</p>
<p>*** Thanks go to <strong>David Biersach </strong>for providing detailed background information for this post. ***</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/389/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/389/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/389/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/389/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/389/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/389/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/389/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/389/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/389/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/389/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/389/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/389/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/389/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/389/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=389&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2011/02/20/enabling-full-stack-dumps-on-asp-net-and-sharepoint-errors/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
		<item>
		<title>Fixing &#8220;Error in the Site Data Web Service&#8221; crawl error in SharePoint 2010</title>
		<link>http://sharepointnomad.wordpress.com/2011/02/18/fixing-error-in-the-site-data-web-service-crawl-error-in-sharepoint-2010/</link>
		<comments>http://sharepointnomad.wordpress.com/2011/02/18/fixing-error-in-the-site-data-web-service-crawl-error-in-sharepoint-2010/#comments</comments>
		<pubDate>Sat, 19 Feb 2011 04:44:39 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[SharePoint administration]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=385</guid>
		<description><![CDATA[I ran into the following issue with search in SharePoint Server 2010 &#8211; the crawl job was failing to index the entire site collection.  Crawl log error:  Error in the Site Data Web Service. (Value does not fall within the expected range.) ULS log error:   &#8220;Error from SharePoint site: Data is Null. This method or property [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=385&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I ran into the following issue with search in SharePoint Server 2010 &#8211; the crawl job was failing to index the entire site collection. </p>
<p>Crawl log error:  Error in the Site Data Web Service. (Value does not fall within the expected range.)<br />
ULS log error:   &#8220;Error from SharePoint site: Data is Null. This method or property cannot be called on Null values.&#8221;</p>
<p>If you turn your diagnostic logging to Verbose, you might see the following error in the ULS log file:</p>
<p>GetSite fail. error 2147755542, strSiteUrl</p>
<p>I was able to fix the problem with the following steps:</p>
<p>1) Ran stsadm -o export command with -includeusersecurity switch to export the site.</p>
<p>2) Additionally, created a full backup of the site (just in case I needed to roll back) using stsadm -o backup command.</p>
<p>3) Deleted the original site collection.</p>
<p>4) Re-created a blank site collection with the same URL and using the same site template.</p>
<p>5) Ran stsadm -o import command with -includeusersecurity switch to import the site.</p>
<p>6) In the Search service application, deleted the original content source containing the problem site collection URL and re-created it with a different name.</p>
<p>7) Reset search index and run a full crawl job.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/385/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/385/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/385/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/385/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/385/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/385/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/385/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/385/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/385/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/385/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/385/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/385/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/385/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/385/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=385&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2011/02/18/fixing-error-in-the-site-data-web-service-crawl-error-in-sharepoint-2010/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
		<item>
		<title>Fix &#8220;Content database with modified database schemas&#8221; issue when upgrading to SharePoint Server 2010</title>
		<link>http://sharepointnomad.wordpress.com/2010/12/12/fix-content-database-with-modified-database-schemas-issue-when-upgrading-to-sharepoint-server-2010/</link>
		<comments>http://sharepointnomad.wordpress.com/2010/12/12/fix-content-database-with-modified-database-schemas-issue-when-upgrading-to-sharepoint-server-2010/#comments</comments>
		<pubDate>Sun, 12 Dec 2010 17:10:33 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[SharePoint administration]]></category>
		<category><![CDATA[Upgrades and migrations]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=367</guid>
		<description><![CDATA[Problem:  You&#8217;re trying to upgrade your farm from MOSS 2007 to SharePoint Server 2010.  When you run stsadm preupgradecheck tool, it reports the following: Issue : Content database with modified database schemas        User modifications to the SharePoint content database, including but not limited to table schemas, index, stored procedures, are not supported and will cause upgrade to [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=367&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Problem:  You&#8217;re trying to upgrade your farm from MOSS 2007 to SharePoint Server 2010.  When you run <strong>stsadm preupgradecheck</strong> tool, it reports the following:</p>
<p><em><strong>Issue : Content database with modified database schemas        </strong></em><br />
<em><strong>User modifications to the SharePoint content database, including but not limited to table schemas, index, stored procedures, are not supported and will cause upgrade to future versions of SharePoint to fail. The databases in the following list seem to have been modified from the original schema:</strong></em></p>
<p><em><strong>Data Source=YourDBServer;Initial Catalog=ProblemDB;Integrated Security=True;Enlist=False;Connect Timeout=15</strong></em></p>
<p>If you did not make any manual changes to your database schemas, then see MS article <a href="http://technet.microsoft.com/en-us/library/cc262967.aspx">http://technet.microsoft.com/en-us/library/cc262967.aspx</a>.  </p>
<p>Otherwise, you can resolve this issue by following the steps below. Make sure to test this out in your test environment and create backups of all production databases before making any changes. </p>
<p>1. Let&#8217;s say your problem database is called &#8220;ProblemDB&#8221;.  In Central Administration, in the same web application where your ProblemDB resides, add a blank content database.   Go to Central Admin site &gt; Application Management &gt; Content Databases.  Switch to the web application in question, click on &#8220;Add a content database&#8221;.  Use the same settings as your ProblemDB, but let&#8217;s call this database &#8220;GoodDB&#8221;.</p>
<p>2. Run the following command<strong> for each site collection </strong>found in the ProblemDB.  This command will move site collections from ProblemDB to GoodDB.</p>
<p><strong>stsadm -o mergecontentdbs -url &lt;site collection URL&gt; -sourcedatabasename ProblemDB -destinationdatabasename GoodDB -operation 2</strong></p>
<p>3. Go to Central Admin site &gt; Application Management &gt; Content Databases and confirm that ProblemDB does not contain any sites. Remove ProblemDB in CA.</p>
<p>4. Restart IIS.</p>
<p>5. Run <strong>stsadm preupgradecheck</strong> tool again to confirm that the issue has been resolved. </p>
<p><span style="text-decoration:underline;">Acknowledgements:  I&#8217;d like to thank Joseph Yi (Datacure, Inc.) for proposing and developing this solution.</span></p>
<p><span style="text-decoration:underline;"> </span></p>
<p>Note:    If you did not make any manual changes to the database schema, you may want to reference the following Microsoft article:</p>
<p>From <a href="http://technet.microsoft.com/en-us/library/cc262967.aspx">http://technet.microsoft.com/en-us/library/cc262967.aspx</a>:</p>
<h4>Upgrading data from SharePoint Portal Server 2003: pre-upgrade checker reports corrupted databases</h4>
<div>
<p>When a content database in an Office SharePoint Server 2007 farm was upgraded from a Microsoft Office SharePoint Portal Server 2003 content database, you might see the following error when you run the pre-upgrade checker:</p>
<p><strong>Failed : Content database with modified database schemas</strong></p>
<p>If you did not make any manual schema changes to the database, you can ignore this error and continue with the ugprade. This is a residual error from the upgrade process from SharePoint Portal Server 2003 to Office SharePoint Server 2007. For more information, see the Microsoft Knowledge Base article <a id="ctl00_MTCS_main_ctl12" href="http://support.microsoft.com/kb/954772" target="_blank">954772</a>.</p>
</div>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/367/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/367/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=367&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2010/12/12/fix-content-database-with-modified-database-schemas-issue-when-upgrading-to-sharepoint-server-2010/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
		<item>
		<title>Some SharePoint Anagrams&#8230;</title>
		<link>http://sharepointnomad.wordpress.com/2010/11/10/some-sharepoint-anagrams/</link>
		<comments>http://sharepointnomad.wordpress.com/2010/11/10/some-sharepoint-anagrams/#comments</comments>
		<pubDate>Thu, 11 Nov 2010 02:48:38 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=360</guid>
		<description><![CDATA[Courtesy of the Internet Anagram Server (http://wordsmith.org): The word &#8220;SharePoint&#8221; can be re-arranged into the following phrases: Tear Siphon Orphan Site Pain Others Train Hopes A Pot Shrine A Shoe Print A The Prison A Open Shirt A Person Hit Share No Tip Heat Or Snip Hate Or Spin Parent So Hi Earn Oh Tips<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=360&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Courtesy of the <strong>Internet Anagram Server</strong> (<a href="http://wordsmith.or">http://wordsmith.org</a>):</p>
<p>The word &#8220;<strong>SharePoint</strong>&#8221; can be re-arranged into the following phrases:</p>
<p>Tear Siphon<br />
Orphan Site<br />
Pain Others<br />
Train Hopes<br />
A Pot Shrine<br />
A Shoe Print<br />
A The Prison<br />
A Open Shirt<br />
A Person Hit<br />
Share No Tip<br />
Heat Or Snip<br />
Hate Or Spin<br />
Parent So Hi<br />
Earn Oh Tips</p>
<p> <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><a href="http://sharepointnomad.files.wordpress.com/2010/11/anim-sharepoint_orphan-site-lqts.gif"><img class="aligncenter size-full wp-image-361" title="anim-SHAREPOINT_ORPHAN-SITE-LqTS" src="http://sharepointnomad.files.wordpress.com/2010/11/anim-sharepoint_orphan-site-lqts.gif?w=500" alt=""   /></a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/360/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/360/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/360/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=360&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2010/11/10/some-sharepoint-anagrams/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>

		<media:content url="http://sharepointnomad.files.wordpress.com/2010/11/anim-sharepoint_orphan-site-lqts.gif" medium="image">
			<media:title type="html">anim-SHAREPOINT_ORPHAN-SITE-LqTS</media:title>
		</media:content>
	</item>
		<item>
		<title>Microsoft SharePoint Part-time Professionals group on LinkedIn</title>
		<link>http://sharepointnomad.wordpress.com/2010/11/02/microsoft-sharepoint-part-time-professionals-group-on-linkedin/</link>
		<comments>http://sharepointnomad.wordpress.com/2010/11/02/microsoft-sharepoint-part-time-professionals-group-on-linkedin/#comments</comments>
		<pubDate>Tue, 02 Nov 2010 18:22:31 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[SharePoint Community]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=356</guid>
		<description><![CDATA[This week I created a new group on LinkedIn called &#8220;Microsoft SharePoint Part-time Professionals&#8220;.  I&#8217;ve been getting quite a few requests for part-time/evening/weekend work for SharePoint developers and administrators, so I decided to start a group and post them there.   I&#8217;ll post here any side work that comes across my desk.  To join the group, do [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=356&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This week I created a new group on LinkedIn called &#8220;<strong>Microsoft SharePoint Part-time Professionals</strong>&#8220;.  I&#8217;ve been getting quite a few requests for part-time/evening/weekend work for SharePoint developers and administrators, so I decided to start a group and post them there.   I&#8217;ll post here any side work that comes across my desk.  To join the group, do the following:</p>
<p>1. Log in to LinkedIn at <a href="http://www.linkedin.com">www.linkedin.com</a>.  If you don&#8217;t already have an account, create one, it&#8217;s free, and will do wonders for your career. </p>
<p>2. In the search box in the upper right corner, search for &#8221;Microsoft SharePoint Part-time Professionals&#8221;.</p>
<p>If you have any part-time/evening SharePoint projects that you need help with, post them in the Discussions area.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/356/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/356/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/356/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/356/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/356/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/356/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/356/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/356/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/356/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/356/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/356/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/356/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/356/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/356/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=356&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2010/11/02/microsoft-sharepoint-part-time-professionals-group-on-linkedin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
		<item>
		<title>PowerShell script to monitor server disk space and send out email alerts</title>
		<link>http://sharepointnomad.wordpress.com/2010/10/29/powershell-script-to-monitor-server-disk-space-and-send-out-email-alerts/</link>
		<comments>http://sharepointnomad.wordpress.com/2010/10/29/powershell-script-to-monitor-server-disk-space-and-send-out-email-alerts/#comments</comments>
		<pubDate>Sat, 30 Oct 2010 00:17:43 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[powershell]]></category>
		<category><![CDATA[SharePoint administration]]></category>
		<category><![CDATA[Windows OS]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=346</guid>
		<description><![CDATA[When you&#8217;re managing a large SharePoint installation, storage issues are going to be a major concern.   Whether it&#8217;s ULS logs, IIS logs,  SQL databases and transaction logs - whatever it is, when left to its own devices, SharePoint can consume a lot of space very quickly, and before you know it, your disks will be running out [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=346&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>When you&#8217;re managing a large SharePoint installation, storage issues are going to be a major concern.   Whether it&#8217;s ULS logs, IIS logs,  SQL databases and transaction logs - whatever it is, when left to its own devices, SharePoint can consume a lot of space very quickly, and before you know it, your disks will be running out of space.</p>
<p>I found a cool PowerShell script by Colin Smith called Disk Space Monitor (see it here:  <a href="http://powershell.com/cs/media/p/1617.aspx">http://powershell.com/cs/media/p/1617.aspx</a>).  For whatever reasons, I had problems getting the email component to work properly, and I also wanted to tweak the email message format.   One thing led to another, and I ended up re-writing a few other sections of Colin&#8217;s script to better suit my needs.  The final product appears below  &#8211; it reads a list of servers, checks the free space on each server, and sends out an email summary to a list of users you specify. </p>
<p>How to use this script:</p>
<p>Step 1.  Create a simple text file with a list of your servers to audit, single column, single-spaced, like this:</p>
<p>server1</p>
<p>server2</p>
<p>server3</p>
<p>server4</p>
<p>&#8230;</p>
<p>Let&#8217;s call the list &#8220;list.txt&#8221;.  Save the file.</p>
<p>Step 2. Create a batch file (let&#8217;s call it &#8220;start.bat&#8221;) and enter the following code in it.  Make sure to enter your own path for the server list as well as the output log file.</p>
<p><pre class="brush: vb; light: true; wrap-lines: false;">

REM  Usage:  powershell %~dp0DiskSpaceMonitor.ps1  &lt;computer list file path&gt;   &lt;output log path&gt;
powershell  %~dp0DiskSpaceMonitor.ps1 C:\Scripts\DiskSpaceMonitor\list.txt   C:\Scripts\DiskSpaceMonitor\output.txt

</pre></p>
<p> </p>
<p>Step 3. Create a PowerShell script file in the same directory as &#8220;start.bat&#8221;,  let&#8217;s call it &#8220;DiskSpaceMonitor.ps1&#8243;, and enter the following code in it.  Make sure to specify your own list of users to email and your SMTP server name or IP address.  Save the file, and execute &#8220;start.bat&#8221;.</p>
<p><pre class="brush: vb; light: true; wrap-lines: false;">
# This script performs the following actions:

#  1) Read a list of servers
#
#  2) For each server on the list, get disk drive information - drive letter, drive size, free space, percent free
#
#  3) Email the report to users specified by the $users variable
#
$users = &quot;user1 @ domain.com&quot;, &quot;user2 @ domain.com &quot; , &quot;user3 @ domain.com&quot;

$server = &quot;SMTP server name or IP address&quot;

$port = 25

$list = $args[0]

$output = $args[1]

$computers = get-content $list

echo &quot;SharePoint Storage Report&quot; &gt; $output
echo &quot; &quot; &gt;&gt; $output
echo &quot;Note: Free space below 30% is labeled with *** &quot; &gt;&gt; $output
echo &quot; &quot; &gt;&gt; $output
echo &quot; &quot; &gt;&gt; $output
echo &quot;ServerName    Drive Letter Drive Size Free Space Percent Free&quot; &gt;&gt; $output
echo &quot;----------    ------------ ---------- ---------- ------------&quot; &gt;&gt; $output
foreach ($line in $computers)
{
 $computer = $line 
 
 $drives = Get-WmiObject -ComputerName $computer Win32_LogicalDisk | Where-Object {$_.DriveType -eq 3}
 foreach($drive in $drives)
 {

 $id = $drive.DeviceID
 $size = [math]::round($drive.Size / 1073741824, 2)
 $free = [math]::round($drive.FreeSpace  / 1073741824, 2)
 $pct = [math]::round($free / $size, 2) * 100
 
 if ($pct -lt 30) { $pct = $pct.ToString() + &quot;% *** &quot; }

 else {  $pct = $pct.ToString() + &quot; %&quot; }

echo &quot;$computer   $id  $size  $free  $pct&quot;  &gt;&gt; $output

$pct = 0 

 }

}
foreach ($user in $users)
{

$to      = $user

$from    = &quot;&lt;a href=&quot;mailto:diskspacemonitor@domain.com&quot;&gt;diskspacemonitor@domain.com&lt;/a&gt;&quot;

$subject = &quot;Connect Storage Report&quot;

foreach ($line in Get-Content $output)

{

$body += “$line `n”

}

# Create mail message

$message = New-Object system.net.mail.MailMessage $from, $to, $subject, $body

#Create SMTP client

$client = New-Object system.Net.Mail.SmtpClient $server, $port

# Credentials are necessary if the server requires the client # to authenticate before it will send e-mail on the client's behalf.

$client.Credentials = [system.Net.CredentialCache]::DefaultNetworkCredentials

# Try to send the message

try {      

$client.Send($message)      

&quot;Message sent successfully&quot;

# reset variables

$body = &quot;&quot;

}

# Catch an error

catch {

&quot;Exception caught in CreateTestMessage1(): &quot;

}

}

# End of Script

 </pre></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/346/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/346/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/346/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/346/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/346/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/346/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/346/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/346/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/346/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/346/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/346/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/346/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/346/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/346/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=346&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2010/10/29/powershell-script-to-monitor-server-disk-space-and-send-out-email-alerts/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
		<item>
		<title>How to enumerate user profiles and their properties in SharePoint 2010 using PowerShell</title>
		<link>http://sharepointnomad.wordpress.com/2010/09/22/how-to-enumerate-user-profiles-and-their-properties-in-sharepoint-2010-using-powershell/</link>
		<comments>http://sharepointnomad.wordpress.com/2010/09/22/how-to-enumerate-user-profiles-and-their-properties-in-sharepoint-2010-using-powershell/#comments</comments>
		<pubDate>Wed, 22 Sep 2010 22:24:19 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[powershell]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[SharePoint administration]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=315</guid>
		<description><![CDATA[When administering a large SharePoint 2010 deployment, there are times when you may need to take an inventory of the user profiles in your profile store &#8211; perhaps to find users with a common property or characteristic, run some comparisons of your SharePoint profiles to Active Directory, or do some other administrative task. Here&#8217;s a [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=315&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>When administering a large SharePoint 2010 deployment, there are times when you may need to take an inventory of the user profiles in your profile store &#8211; perhaps to find users with a common property or characteristic, run some comparisons of your SharePoint profiles to Active Directory, or do some other administrative task.</p>
<p>Here&#8217;s a simple PowerShell script that enumerates all user profiles in the context of your SharePoint site and emits some of their properties, such as Display Name, AccountName, and workEmail.</p>
<p>Note:  The account which will be executing this script needs to have Full Control access to the User Profile Service application.   Follow these two steps:</p>
<p>1) Go to  Central Administration &gt; Manage service applications &gt; select (highlight) your user profile application &gt; click on Administrators button on the ribbon and add your account.</p>
<p>2) Go to  Central Administration &gt; Manage service applications &gt; select (highlight) your user profile application &gt; click on Permissions button on the ribbon and add your account with Full Control &#8211; make sure to check the &#8220;Full Control&#8221; checkbox!</p>
<p><pre class="brush: vb; light: true; wrap-lines: false;">

[void][System.Reflection.Assembly]::LoadWithPartialName(&quot;Microsoft.Office.Server&quot;)
[void][System.Reflection.Assembly]::LoadWithPartialName(&quot;Microsoft.Office.Server.UserProfiles&quot;)
[void][System.Reflection.Assembly]::LoadWithPartialName(&quot;Microsoft.SharePoint&quot;)
# Enter your SharePoint site URL here...
$site = new-object Microsoft.SharePoint.SPSite(&quot;http://...&quot;);

$ServiceContext = [Microsoft.SharePoint.SPServiceContext]::GetContext($site);

$ProfileManager = new-object Microsoft.Office.Server.UserProfiles.UserProfileManager($ServiceContext)

$AllProfiles = $ProfileManager.GetEnumerator()

write-host &quot;Display Name ;  AccountName ; Email ; &quot;

foreach($profile in $AllProfiles)
{

$DisplayName = $profile.DisplayName

$AccountName = $profile[[Microsoft.Office.Server.UserProfiles.PropertyConstants]::AccountName].Value

$workEmail = $profile[[Microsoft.Office.Server.UserProfiles.PropertyConstants]::workEmail].Value

write-host $DisplayName, &quot;;&quot;, $AccountName, &quot;;&quot; , $workEmail, &quot;;&quot;

}
write-host &quot;Finished.&quot;

$site.Dispose()

</pre></p>
<p>A full list of SP 2010 user profile properties is available on MSDN here:</p>
<p><a href="http://msdn.microsoft.com/en-us/library/microsoft.office.server.userprofiles.propertyconstants_members.aspx">http://msdn.microsoft.com/en-us/library/microsoft.office.server.userprofiles.propertyconstants_members.aspx</a><a href="http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.portal.userprofiles.propertyconstants_members(v=office.12).aspx"></a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/315/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/315/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/315/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/315/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/315/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/315/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/315/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/315/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/315/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/315/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/315/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/315/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/315/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/315/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=315&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2010/09/22/how-to-enumerate-user-profiles-and-their-properties-in-sharepoint-2010-using-powershell/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
		<item>
		<title>How to programmatically delete items in a SharePoint list</title>
		<link>http://sharepointnomad.wordpress.com/2010/08/22/how-to-programmatically-delete-items-in-a-sharepoint-list/</link>
		<comments>http://sharepointnomad.wordpress.com/2010/08/22/how-to-programmatically-delete-items-in-a-sharepoint-list/#comments</comments>
		<pubDate>Sun, 22 Aug 2010 13:32:06 +0000</pubDate>
		<dc:creator>andrei338</dc:creator>
				<category><![CDATA[SharePoint development]]></category>

		<guid isPermaLink="false">http://sharepointnomad.wordpress.com/?p=310</guid>
		<description><![CDATA[I was looking for a way to programmatically delete items in a SharePoint list, and I found this great post by DevExpert: http://www.devexpertise.com/2009/02/04/deleting-list-items-in-a-sharepoint-list/ The author outlines four incorrect methods for doing it, and one correct method.  It turns out that you need to use a For loop with a decrementing counter, like this: &#60;code&#62; for [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=310&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I was looking for a way to programmatically delete items in a SharePoint list, and I found this great post by <a href="http://www.devexpertise.com/">DevExpert</a>:</p>
<p><a href="http://www.devexpertise.com/2009/02/04/deleting-list-items-in-a-sharepoint-list/">http://www.devexpertise.com/2009/02/04/deleting-list-items-in-a-sharepoint-list/</a></p>
<p>The author outlines four incorrect methods for doing it, and one correct method.  It turns out that you need to use a For loop with a decrementing counter, like this:</p>
<p>&lt;code&gt;</p>
<pre>for (int i = list.Items.Count - 1; i &gt;= 0; i--) {
    list.Items.Delete(i);
}
&lt;/code&gt;
Great post!</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointnomad.wordpress.com/310/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointnomad.wordpress.com/310/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointnomad.wordpress.com/310/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointnomad.wordpress.com/310/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointnomad.wordpress.com/310/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointnomad.wordpress.com/310/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointnomad.wordpress.com/310/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointnomad.wordpress.com/310/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointnomad.wordpress.com/310/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointnomad.wordpress.com/310/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointnomad.wordpress.com/310/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointnomad.wordpress.com/310/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointnomad.wordpress.com/310/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointnomad.wordpress.com/310/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointnomad.wordpress.com&amp;blog=6838793&amp;post=310&amp;subd=sharepointnomad&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointnomad.wordpress.com/2010/08/22/how-to-programmatically-delete-items-in-a-sharepoint-list/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/524414d5589c8650881686b59870c574?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">andrei338</media:title>
		</media:content>
	</item>
	</channel>
</rss>
