<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><title type="html">SharePoint Skater</title><subtitle type="html">Custom control and client script aficionado, neck-deep in a simmering SharePoint stew.</subtitle><id>http://weblogs.asp.net/peterbrunone/atom.aspx</id><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/default.aspx" /><link rel="self" type="application/atom+xml" href="http://weblogs.asp.net/peterbrunone/atom.aspx" /><generator uri="http://communityserver.org" version="3.0.20510.895">Community Server</generator><updated>2009-05-13T12:52:00Z</updated><entry><title>Practical Tweaks:  creating a Social Security Number column</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/10/19/practical-tweaks-creating-a-social-security-number-column.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/10/19/practical-tweaks-creating-a-social-security-number-column.aspx</id><published>2009-10-19T17:49:00Z</published><updated>2009-10-19T17:49:00Z</updated><content type="html">&lt;p&gt;Many people find SharePoint to be somewhat limiting in its out-of-the-box functionality, but really, a creative approach can take you pretty far.&amp;nbsp; Say, for example, you need to create a column to hold Social Security numbers (assuming you've worked out all the relevant security issues).&amp;nbsp; You have a field that requires numeric validation, but it has a specific length requirement, which sounds more like string validation.&amp;nbsp; Here's what I came up with off the cuff:&lt;/p&gt;&lt;ol&gt;&lt;li&gt;Create a new Site Column.&amp;nbsp; Add it to whatever group makes sense (I picked Core Contact and Calendar Columns).&lt;/li&gt;&lt;li&gt;Give it a name and a datatype of Number.&lt;/li&gt;&lt;li&gt;Specify a maximum of 999999999 to take care of the ten-digit formatting issue.&lt;/li&gt;&lt;li&gt;Explicitly set &lt;b&gt;Number of decimal places&lt;/b&gt; to zero.&lt;img src="file:///C:/Users/ADMINI%7E1/AppData/Local/Temp/1/moz-screenshot.png" mce_src="file:///C:/Users/ADMINI%7E1/AppData/Local/Temp/1/moz-screenshot.png" alt=""&gt;&lt;/li&gt;&lt;li&gt;Click &lt;b&gt;OK.&lt;/b&gt;&lt;br&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;&amp;nbsp;That's it.&amp;nbsp; Next time we'll look at masking/validating your user's input for this field.&lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7233151" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>Backup horror stories:  Rendering error in the global navigation tab</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/10/06/backup-horror-stories-rendering-error-in-the-global-navigation-tab.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/10/06/backup-horror-stories-rendering-error-in-the-global-navigation-tab.aspx</id><published>2009-10-06T05:58:00Z</published><updated>2009-10-06T05:58:00Z</updated><content type="html">&lt;p&gt;Chances are that if you're restoring a site collection from backup, something has gone seriously wrong.&amp;nbsp; Naturally, at this point, you've had just about enough of unexpected glitches, and you REALLY don't want anything to look weird once you restore and load up the site again.&amp;nbsp; Oh, but Mr. Murphy is there laying down the law, and all you see on the global nav is a big "Error" tab.&amp;nbsp; Terrified, you mouse over it with a morbid curiosity, only to discover the following error in a tooltip:&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;An error occured while rendering navigation for requested URL: /.
Exception message: Object reference not set to an instance of an
object. Stack trace:&amp;nbsp;&amp;nbsp;&amp;nbsp; at
Microsoft.SharePoint.Publishing.PublishingWeb.&amp;amp;lt;&amp;gt;c__DisplayClass2d.&amp;amp;lt;CleanupInternalIDs&amp;gt;b__2c()&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.SPSecurity.CodeToRunElevatedWrapper(Object state)&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.SPSecurity.&amp;amp;lt;&amp;gt;c__DisplayClass4.&amp;amp;lt;RunWithElevatedPrivileges&amp;gt;b__2()&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.Utilities.SecurityContext.RunAsProcess(CodeToRunElevated secureCode)&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(WaitCallback secureCode, Object param)&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(CodeToRunElevated secureCode)&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.Publishing.PublishingWeb.CleanupInternalIDs(PublishingWeb pubwebToCleanUp)&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.Publishing.PublishingWeb.get_PagesList()&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.Publishing.CachedArea.GetChildPageIds()&lt;br&gt;&amp;nbsp;&amp;nbsp;
at
Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider.UserHasRightsToCachedObject(CachedObject
cachedObject, SPWeb currentContext)&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.Publishing.Navigation.CachedObjectSiteMapNode.IsAccessibleToUser(SPWeb contextWeb)&lt;br&gt;&amp;nbsp;&amp;nbsp;
at
Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapNode.GetNavigationChildren(NodeTypes
includedTypes, NodeTypes includedHiddenTypes, OrderingMethod ordering,
AutomaticSortingMethod method, Boolean ascending, Int32 lcid)&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapNode.GetNavigationChildren(NodeTypes includedHiddenTypes)&lt;br&gt;&amp;nbsp;&amp;nbsp; at Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider.GetChildNodes(PortalSiteMapNode node, NodeTypes &lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;Of course I can't speak for everyone in every situation, but this kind of thing late at night when everything else has hit the fan...&amp;nbsp; it's enough to make you want to swap careers with Old MacDonald (seriously, what kind of farm grows moss?).&lt;/p&gt;&lt;p&gt;But enough about my midnight work hallucinations.&amp;nbsp; At this point, the most helpful thing to do -- assuming you still have that backup -- is to delete the site collection entirely.&amp;nbsp; Go into Central Admin, click Application Management, and blow that site collection away.&amp;nbsp; THEN go back and restore from backup again.&lt;/p&gt;&lt;p&gt;If that doesn't work, then run the Config Wizard again; that'll usually shake something loose.&lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7223889" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>Why my MOSS search doesn't work today (Reason #316)</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/08/27/why-my-moss-search-doesn-t-work-today-reason-316.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/08/27/why-my-moss-search-doesn-t-work-today-reason-316.aspx</id><published>2009-08-28T02:12:00Z</published><updated>2009-08-28T02:12:00Z</updated><content type="html">&lt;p&gt;Earlier this week a client called.&amp;nbsp; Our beautiful MOSS installation had been running beautifully, and then several days after a reboot... their Search completely stopped working.&lt;/p&gt;&lt;p&gt;Naturally, I hopped on the VPN, logged on to the server via RDP, and checked all the usual things.&amp;nbsp; Windows SharePoint Search Service was running, and the MOSS Crawl Schedule looked right, so I decided to see for myself... except the portal wouldn't authenticate me.&lt;/p&gt;&lt;p&gt;Aha.&amp;nbsp; Just after a reboot, you say?&amp;nbsp; If only I'd had the good sense to look at the crawl logs (they were full of 401.1-type "Access Denied" errors). &lt;/p&gt;&lt;p&gt;This is nothing less than the dreaded loopback check.&amp;nbsp; Apparently, Microsoft feels that it is a security risk for one to access a website from that same server (but only on port 80; all other ports appear to be wide open).&amp;nbsp; To get around this, they actually recommend a registry hack -- er, tweak -- that is detailed in &lt;a href="http://support.microsoft.com/kb/896861" title="KB 896861 -- disable loopback check" mce_href="http://support.microsoft.com/kb/896861"&gt;MS KB article 896861&lt;/a&gt;.&amp;nbsp; I'm including the procedure below on the off chance that the article goes dead someday; my preferred choice is method 2, but you may have other needs.&lt;br&gt;&lt;/p&gt;&lt;h3 id="tocHeadRef"&gt;Method 1: Specify host names&lt;/h3&gt;&lt;script type="text/javascript"&gt;
                loadTOCNode(2, 'workaround');
            &lt;/script&gt;&lt;b&gt;Note&lt;/b&gt; We recommend that you use this method.&lt;br&gt;&lt;br&gt;To
specify the host names that are mapped to the loopback address and can
connect to Web sites on your computer, follow these steps:&lt;ol&gt;&lt;li&gt;Click &lt;strong class="uiterm"&gt;Start&lt;/strong&gt;, click &lt;strong class="uiterm"&gt;Run&lt;/strong&gt;, type &lt;span class="userInput"&gt;regedit&lt;/span&gt;, and then click &lt;strong class="uiterm"&gt;OK&lt;/strong&gt;.&lt;/li&gt;&lt;li&gt;In Registry Editor, locate and then click the following registry key: &lt;div class="indent"&gt;&lt;strong class="uiterm"&gt;HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa\MSV1_0&lt;/strong&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;Right-click &lt;strong class="uiterm"&gt;MSV1_0&lt;/strong&gt;, point to &lt;strong class="uiterm"&gt;New&lt;/strong&gt;, and then click &lt;strong class="uiterm"&gt;Multi-String Value&lt;/strong&gt;.&lt;/li&gt;&lt;li&gt;Type &lt;span class="userInput"&gt;BackConnectionHostNames&lt;/span&gt;, and then press ENTER.&lt;/li&gt;&lt;li&gt;Right-click &lt;strong class="uiterm"&gt;BackConnectionHostNames&lt;/strong&gt;, and then click &lt;strong class="uiterm"&gt;Modify&lt;/strong&gt;.&lt;/li&gt;&lt;li&gt;In the &lt;strong class="uiterm"&gt;Value data&lt;/strong&gt; box, type the host name or the host names for the sites that are on the local  computer, and then click &lt;strong class="uiterm"&gt;OK&lt;/strong&gt;.&lt;/li&gt;&lt;li&gt;Quit Registry Editor, and then restart the IISAdmin service.&lt;/li&gt;&lt;/ol&gt;&lt;h3 id="tocHeadRef"&gt;Method 2: Disable the loopback check &lt;/h3&gt;&lt;script type="text/javascript"&gt;
                loadTOCNode(2, 'workaround');
            &lt;/script&gt;Follow these steps:&lt;ol&gt;&lt;li&gt;Click &lt;strong class="uiterm"&gt;Start&lt;/strong&gt;, click &lt;strong class="uiterm"&gt;Run&lt;/strong&gt;, type &lt;span class="userInput"&gt;regedit&lt;/span&gt;, and then click &lt;strong class="uiterm"&gt;OK&lt;/strong&gt;.&lt;/li&gt;&lt;li&gt;In Registry Editor, locate and then click the following registry key: &lt;div class="indent"&gt;&lt;strong class="uiterm"&gt;HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa&lt;/strong&gt;&lt;/div&gt;&lt;/li&gt;&lt;li&gt;Right-click &lt;strong class="uiterm"&gt;Lsa&lt;/strong&gt;, point to &lt;strong class="uiterm"&gt;New&lt;/strong&gt;, and then click &lt;strong class="uiterm"&gt;DWORD Value&lt;/strong&gt;.&lt;/li&gt;&lt;li&gt;Type &lt;span class="userInput"&gt;DisableLoopbackCheck&lt;/span&gt;, and then press ENTER.&lt;/li&gt;&lt;li&gt;Right-click &lt;strong class="uiterm"&gt;DisableLoopbackCheck&lt;/strong&gt;, and then click &lt;strong class="uiterm"&gt;Modify&lt;/strong&gt;.&lt;/li&gt;&lt;li&gt;In the &lt;strong class="uiterm"&gt;Value data&lt;/strong&gt; box, type &lt;span class="userInput"&gt;1&lt;/span&gt;, and then click &lt;strong class="uiterm"&gt;OK&lt;/strong&gt;.&lt;/li&gt;&lt;li&gt;Quit Registry Editor, and then restart your computer.&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7183660" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Administration" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Administration/default.aspx" /><category term="Search" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Search/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>The Great Divorce:  Separating site hierarchy from navigation</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/07/31/the-great-divorce-separating-site-hierarchy-from-navigation.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/07/31/the-great-divorce-separating-site-hierarchy-from-navigation.aspx</id><published>2009-07-31T17:02:00Z</published><updated>2009-07-31T17:02:00Z</updated><content type="html">&lt;p&gt;(apologies to Clive Lewis)&lt;/p&gt;&lt;p&gt;It's a simple concept, really.&amp;nbsp; Create your SharePoint site structure to accommodate permission inheritance, not navigation.&amp;nbsp; You can always alter the content and appearance of Global Nav or Quick Launch, so why constrain your hierarchy to something that will probably change?&lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7158919" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /><category term="User Experience" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/User+Experience/default.aspx" /></entry><entry><title>Hyper-V fun fact</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/07/28/hyper-v-fun-fact.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/07/28/hyper-v-fun-fact.aspx</id><published>2009-07-28T17:19:00Z</published><updated>2009-07-28T17:19:00Z</updated><content type="html">&lt;p&gt;Have you ever needed to back up a VHD with a script?&amp;nbsp; If you have, then you've probably wanted to make sure it copied successfully.&lt;/p&gt;&lt;p&gt;One simple test is to check the size of both the source file and the destination file; this sounds great until you bang your head against the wall in frustration when, two hours later, you can't figure out why the file sizes still don't match.&lt;/p&gt;&lt;p&gt;Allow me to explain.&lt;/p&gt;&lt;p&gt;When you back up a Hyper-V machine, the first thing you do is to stop the VM for the duration.&amp;nbsp; Essentially, this just tells the virtual machine manager to stop writing to the VHD, giving you a static target... &lt;i&gt;&lt;b&gt;but&lt;/b&gt;&lt;/i&gt; in the process, it marks the file which changes the size.&amp;nbsp; Ergo, you have a 4KB difference in your VHD size between "started" and "stopped" states.&lt;/p&gt;&lt;p&gt;The solution?&amp;nbsp; Make sure your VM is off for another second while you get that all-important file size.&amp;nbsp; Then start it up again, and off you go. &lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7156071" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Administration" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Administration/default.aspx" /><category term="General Software Development" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/General+Software+Development/default.aspx" /><category term="Hyper-V" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Hyper-V/default.aspx" /></entry><entry><title>My favorite new quick fix:  MS Office Diagnostics</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/07/10/my-favorite-new-quick-fix-ms-office-diagnostics.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/07/10/my-favorite-new-quick-fix-ms-office-diagnostics.aspx</id><published>2009-07-10T18:16:00Z</published><updated>2009-07-10T18:16:00Z</updated><content type="html">&lt;p&gt;Rebooting cures a multitude of ills. &lt;br&gt;&lt;br&gt;Over the past two years I've come to realize that the SharePoint server equivalent is to run the SharePoint Products and Technologies Configuration Wizard (what a mouthful &lt;i&gt;that &lt;/i&gt;is).&amp;nbsp; However, my latest discovery is that there is a client equivalent as well.&lt;br&gt;&lt;br&gt;If a user complains of JavaScript errors (e.g. "Library not registered"), of Excel 2007 documents opening in Excel 2003, or a handful of other SharePoint-related client-side issues, I now point them directly to the MS Office Diagnostic Tool.&amp;nbsp; Here's the basic procedure: &lt;br&gt;&lt;br&gt;1.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Open Word 2007 (or Excel 2007).&lt;br&gt;2.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Click the Office button.&lt;br&gt;3.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Click the &lt;b&gt;Word Options&lt;/b&gt; (or &lt;b&gt;Excel Options&lt;/b&gt;) button on the resulting menu.&lt;br&gt;4.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Select the &lt;b&gt;Resources &lt;/b&gt;tab on the left.&lt;br&gt;5.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Click the &lt;b&gt;Diagnose &lt;/b&gt;button.&lt;br&gt;6.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Start the diagnostic tests and follow the prompts.&lt;/p&gt;&lt;p&gt;The tests will take a few minutes to run, after which the results will be displayed (e.g. 1 defect fixed).&amp;nbsp; At this point you can go back and try the offending procedure again... and most likely, the error will be gone.&lt;/p&gt;&lt;p&gt;Additional info:&amp;nbsp; the relevant executable is located at &lt;b&gt;C:\Program Files\Common Files\microsoft shared\OFFDIAG.EXE&lt;/b&gt;.&amp;nbsp; Administrators may find this useful for remote execution at login, etc. for curative or preventative purposes.&amp;nbsp; There's no official way to launch it without user intervention, but you could easily run the file with VBScript or .NET code and then use SendKeys to kick it off.&lt;br&gt;&lt;/p&gt;&lt;p&gt;Feel free to contact me with additional problems that this solves; I'd like to keep an updated list here.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7144978" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /><category term="MS Office" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/MS+Office/default.aspx" /></entry><entry><title>Hiding the Recycle Bin</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/07/09/hiding-the-recycle-bin.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/07/09/hiding-the-recycle-bin.aspx</id><published>2009-07-09T19:14:00Z</published><updated>2009-07-09T19:14:00Z</updated><content type="html">
&lt;p&gt;The SharePoint Recycle Bin is a very useful feature, but due to the lack of a separate permission structure, sometimes product owners want to hide it from their users.&amp;nbsp; This can be done in a variety of ways, but I've found that the simplest is to create a new master page (usually from a downloaded copy of the one you currently use on your site) and find the following tag:&lt;/p&gt;

&lt;p style="font-size: 8pt; font-family: courier;"&gt;&amp;lt;SharePoint:SPLinkButton runat="server" NavigateUrl="~site/layouts/recyclebin.aspx" id=idNavLinkRecycleBin" ... &lt;br&gt;
(there's a lot more) &lt;/p&gt;

&lt;p&gt;Simply add the Visible="False" attribute to the tag.&amp;nbsp; This will hide the Recycle Bin link on the Quick Launch and allow you to retrieve it at any time.&amp;nbsp; You won't need SharePoint Designer or Visual Studio -- you can do this with Notepad once you've downloaded the file -- and the whole thing, from when you download a copy to when you Publish/Approve the new master page, takes less than a minute.&lt;br&gt;&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7143963" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="SharePoint Customization" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/SharePoint+Customization/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>SPTraceView:  One step closer to unscrewing the inscrutable</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/07/02/sptraceview-one-step-closer-to-unscrewing-the-inscrutable.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/07/02/sptraceview-one-step-closer-to-unscrewing-the-inscrutable.aspx</id><published>2009-07-02T14:46:00Z</published><updated>2009-07-02T14:46:00Z</updated><content type="html">&lt;p&gt;We still don't have good SharePoint debugging, but today I came across a tool that gets us closer.&amp;nbsp; Essentially it works off of the SP logging mechanism, and alerts you when messages come up that meet your predefined filters.&amp;nbsp; This has the advantage of (a) keeping you from having to go through the log files line by line, and (b) filtering at a higher level, allowing you to keep all that log information rather than excluding some events from being logged.&lt;/p&gt;&lt;p&gt;Give it a shot at &lt;a href="http://sptraceview.codeplex.com/" title="SPTraceView on CodePlex" mce_href="http://sptraceview.codeplex.com/"&gt;http://sptraceview.codeplex.com/&lt;/a&gt; .&lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7138680" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="General Software Development" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/General+Software+Development/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>PSConfig Part III:  Confessions and assumptions</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/06/04/psconfig-part-iii-confessions-and-assumptions.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/06/04/psconfig-part-iii-confessions-and-assumptions.aspx</id><published>2009-06-04T12:59:00Z</published><updated>2009-06-04T12:59:00Z</updated><content type="html">&lt;p&gt;It's happened to everyone.&amp;nbsp; You're supposed to be an expert in your field, and then you go and get tripped up by something insignificant.&amp;nbsp; If you're like me, you think you've already eliminated the offending possibility, and it's only after the client (ack!) checks out your assumptions that you realize your foolish mistake (in this case, it was the assumption that the server's software firewall had nothing to do with the problem... but it did).&lt;/p&gt;&lt;p&gt;So there I was, running PSConfig on a two-server farm (one MOSS box, one SQL 2008 box), and I got the following error:&lt;/p&gt;&lt;p&gt;&lt;span style="color: rgb(255, 0, 0);"&gt;The server parameter specified
with the configdb command is invalid.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="color: rgb(255, 0, 0);"&gt;Failed to connect to the database
server or the database name does not exist. Ensure the database server
exists, is a Sql server, and that you have the appropriate permissions
to access the database server. To diagnose the problem, review the
extended error information located at C:\Program Files\Common
Files\Microsoft Shared\Web Server Extensions\12\LOGS\PSCDiagnostics...&lt;/span&gt; &lt;/p&gt;&lt;p&gt;Since these were all new accounts for the MOSS farm, I thought they didn't have proper access (this had been a problem the previous day)... but no, I could log on to the DB server just fine.&amp;nbsp; I noticed, however, that I couldn't get into SQL Management Studio via Windows authentication; this led me to all the usual checks for Windows auth, TCP/IP, remote connections, etc.&lt;/p&gt;&lt;p&gt;At some point after contacting the DBA, that local login problem went away, but I had already let it steer me down a rabbit trail.&amp;nbsp; At that point my mind should have shifted back into "obvious mode", but I'm a hardcore geek, for crying out loud; this doesn't come easy for me.&amp;nbsp; Suffice it to say that you should always, ALWAYS go through your "duh" checklist again, even if you think you've covered it all.&lt;/p&gt;&lt;p&gt;One final note:&amp;nbsp; while searching for clues on this crazy chase, I came across someone who claimed that their problem was an incorrect collation mode on an already-created database.&amp;nbsp; The latest version of MOSS (as of this writing) gives a more specific error if that is indeed the problem (but don't let me keep you from checking it just in case!)&lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7108034" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="General Software Development" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/General+Software+Development/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>SharePoint Migration from 2003 to 2007:  Leave the clutter behind.</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/05/29/sharepoint-migration-from-2003-to-2007-leave-the-clutter-behind.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/05/29/sharepoint-migration-from-2003-to-2007-leave-the-clutter-behind.aspx</id><published>2009-05-29T21:09:00Z</published><updated>2009-05-29T21:09:00Z</updated><content type="html">&lt;p&gt;This has come up several times recently, and I think it's another case of the "Microsoft offers it so we should use it" mentality.&amp;nbsp; There are indeed tools and utilities for migrating your existing farm -- or content database(s), or site collection(s) from 2003 to 2007; there are even procedures for upgrading your SharePoint farm to the new version.&lt;/p&gt;&lt;p&gt;Having been all over that mess, I can't recommend it. &lt;br&gt;&lt;/p&gt;&lt;p&gt;In fact, we almost always advise &lt;i&gt;&lt;b&gt;not&lt;/b&gt;&lt;/i&gt; migrating everything in bulk, in favor of
having the users themselves bring over their relevant content.&lt;br&gt;&lt;br&gt;Here's
an analogy:&amp;nbsp; when you build a new house, you don't build it around the
old one and hope everything fits.&amp;nbsp; You build in a new location (or
perhaps the old if you're demolishing first), and then take what you
want and place it where it should go in the new house.&amp;nbsp; Along the way,
you discover a lot of things that you don't need; as a result, they get thrown away
or given to someone else, and you have less clutter.&lt;br&gt;
&lt;br&gt;Of course there are exceptions, but -- generally speaking -- this
approach (a) puts responsibility in the hands of the business users who
actually *care* about their content, and (b) doesn't bind you to the
old way of doing things.&amp;nbsp; It's a chance to go forward without the
baggage of the past, to cash in on hindsight, to invent new cliches...
and it shows you what content people are actually using.&lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7102153" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="SharePoint Migration" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/SharePoint+Migration/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>PSConfig revisited:  character analysis</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/05/28/character-analysis.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/05/28/character-analysis.aspx</id><published>2009-05-28T14:50:00Z</published><updated>2009-05-28T14:50:00Z</updated><content type="html">&lt;p&gt;After &lt;a href="http://weblogs.asp.net/peterbrunone/archive/2009/05/27/psconfig-helpful-tool-unhelpful-error-messages.aspx" mce_href="http://weblogs.asp.net/peterbrunone/archive/2009/05/27/psconfig-helpful-tool-unhelpful-error-messages.aspx"&gt;yesterday's&lt;/a&gt; brush with covert crazy hyphens, a related tip seems in order.&lt;/p&gt;


&lt;p&gt;This isn't the first time I've been burned by non-standard characters.&amp;nbsp; Several years back I created a small classic ASP utility (yes, it's THAT old) that analyzes a string and spits out the unicode values; you can use it in the iframe below.&lt;/p&gt;

&lt;p&gt;As a sample, here are two identical sections of the PSConfig script -- one with proper dashes, and one with the offending content.&amp;nbsp; You can copy/paste each into the tool below to see how obvious the problem is. &lt;br&gt;&lt;/p&gt;

&lt;p&gt;&lt;u&gt;Normal:&lt;/u&gt;&lt;br&gt;
Psconfig -cmd configdb -create -server &amp;lt;SQL_servername&amp;gt; -database &amp;lt;precreated_configDB&amp;gt; &lt;br&gt;&lt;/p&gt;

&lt;p&gt;&lt;u&gt;Disturbed:&lt;/u&gt;&lt;br&gt;
Psconfig –cmd configdb –create –server &amp;lt;SQL_servername&amp;gt; -database &amp;lt;precreated_configDB&amp;gt;&lt;br&gt;&lt;/p&gt;
&lt;iframe src="http://easylistbox.com/stuff/analyzethis.asp" mce_src="http://easylistbox.com/stuff/analyzethis.asp" style="border: 0px solid white; height: 400px; width: 500px;"&gt;&lt;/iframe&gt;
&lt;p&gt;&amp;nbsp;Alpha characters are shown in blue, with numerics in green.&amp;nbsp; Normal "extra" characters are yellow/beige, and out-of-range weirdness is highlighted in red.&lt;br&gt;&lt;/p&gt;

&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7100380" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="General Software Development" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/General+Software+Development/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>PSConfig:  helpful tool, unhelpful error messages</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/05/27/psconfig-helpful-tool-unhelpful-error-messages.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/05/27/psconfig-helpful-tool-unhelpful-error-messages.aspx</id><published>2009-05-27T21:01:00Z</published><updated>2009-05-27T21:01:00Z</updated><content type="html">
&lt;p&gt;Earlier this week, I needed to set up a MOSS development box.&amp;nbsp; Piece of cake, right?&amp;nbsp; Well, I must have been really tired from the long weekend, because when I used PSConfig to pre-create the configuration database, the following error stopped me dead in my tracks:&lt;/p&gt;

&lt;p&gt;&lt;span style="font-size: 11pt; font-family: 'Calibri','sans-serif';"&gt;“The -cmd command is invalid.”&lt;br&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;For those of you not familiar with PSConfig.exe, it's a nice little built-in utility that allows you to create your configuration database and admin content database with a pre-determined name instead of the unholy string of nonsense that MOSS autogenerates.&amp;nbsp; You can run from in the /bin folder under the 12 hive, with the following syntax (all on one line):&lt;/p&gt;

&lt;p&gt;Psconfig.exe -cmd configdb -create -server &amp;lt;SQL_Server_Name&amp;gt; -database &amp;lt;New_Config_Database_Name&amp;gt; -user &amp;lt;domain\Database_Access_Account&amp;gt; -password &amp;lt;Database_Access_Password&amp;gt; -admincontentdatabase &amp;lt;New_Admin_Content_Database_Name&amp;gt;&lt;/p&gt;

&lt;p&gt;Be sure to replace the angle-bracketed parameters with the correct values.&lt;/p&gt;

&lt;p&gt;Normally this works like a charm, and if not, the resulting error message will tell you what needs changing.&amp;nbsp; In my haste, however, I had copy/pasted the string from a web page and filled in my own values.&amp;nbsp; The result was that I had some non-standard hyphens, and that made the whole thing choke.&amp;nbsp; The solution?&amp;nbsp; Delete all the hyphen (dash) characters and re-type them.&amp;nbsp; Problem solved.&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7100358" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>Anonymous users and SharePoint workflows:  The Problem</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/05/21/anonymous-users-and-sharepoint-workflows-the-problem.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/05/21/anonymous-users-and-sharepoint-workflows-the-problem.aspx</id><published>2009-05-21T15:10:00Z</published><updated>2009-05-21T15:10:00Z</updated><content type="html">&lt;p&gt;Simply put, you can't trigger a workflow from an anonymous user.&amp;nbsp; The workflow must run in the context of the current user account, and of course there isn't one when you're anonymous.&amp;nbsp; If you do try it, you'll probably see the following error:&lt;/p&gt;&lt;blockquote&gt;&lt;p&gt;&lt;b&gt;&lt;i&gt;&amp;nbsp;The data source control failed to execute the insert command.&lt;/i&gt;&lt;/b&gt;&lt;/p&gt;&lt;/blockquote&gt;&lt;p&gt;This is misleading because the item &lt;i&gt;does&lt;/i&gt; get added to the list.&amp;nbsp; It's the subsequent event (start workflow) that gets confused and curls up in a fetal position while humming manic strains of obscure nursery rhymes.&lt;/p&gt;&lt;p&gt;Since most people seem to think it's impossible to do this, I'm going to give it a try.&amp;nbsp; Hopefully I'll have some meaningful results to share soon.&lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7094157" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Anonymous Access" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Anonymous+Access/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /><category term="Workflow" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Workflow/default.aspx" /></entry><entry><title>SharePoint Designer Gotcha:  Where's the "action" in my Form Action button?</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/05/15/sharepoint-designer-gotcha-where-s-the-quot-action-quot-in-my-form-action-button.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/05/15/sharepoint-designer-gotcha-where-s-the-quot-action-quot-in-my-form-action-button.aspx</id><published>2009-05-15T17:04:00Z</published><updated>2009-05-15T17:04:00Z</updated><content type="html">&lt;p&gt;It seemed simple enough.&lt;/p&gt;
&lt;p&gt;I built a custom New Item form.&amp;nbsp; Naturally, it needed to redirect to another page after completion.&amp;nbsp; Normally for a "return page" function, a "Source" parameter in the querystring will suffice, but that didn't seem to work here.&amp;nbsp; I found the Form Action Button (under Insert-&amp;gt;SharePoint Controls-&amp;gt;More SharePoint Controls), added Commit and Redirect actions, told it what page to use, and presto!&lt;/p&gt;
&lt;p&gt;Nothing happened. &lt;/p&gt;
&lt;p&gt;In fact, it didn't even try to submit the form.&lt;/p&gt;
&lt;p&gt;A look at the markup revealed that the "Form Action Button" was just a regular old input type="button".&amp;nbsp; SharePoint Designer was supposed to add an event handler with a JavaScript call, but there appears to be a bug in Designer.&amp;nbsp; Apparently if there is another HTML button nearby, the event handler can end up there instead!&amp;nbsp; I've included the code so you know what to look for if this ever happens to you:&lt;/p&gt;
&lt;p style="font-family: courier;"&gt;&amp;nbsp; onclick="javascript: {ddwrt:GenFireServerEvent('__commit;__redirect={Thanks.aspx}')}"&lt;/p&gt;
&lt;p&gt;Your actions may be slightly different, but that's the basic idea.&amp;nbsp; All you need to do is to cut/paste this bit into your *actual* button -- or any other control, really -- and you'll have the behavior you expected in the first place.&lt;/p&gt;&lt;p&gt;Whew.&lt;br&gt;&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7088086" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="SharePoint Designer" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/SharePoint+Designer/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry><entry><title>Fun with MOSS Search, Part I:  Service Packs and Registry Hacks</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/peterbrunone/archive/2009/05/13/service-packs-and-registry-hacks.aspx" /><id>http://weblogs.asp.net/peterbrunone/archive/2009/05/13/service-packs-and-registry-hacks.aspx</id><published>2009-05-13T17:52:00Z</published><updated>2009-05-13T17:52:00Z</updated><content type="html">&lt;p&gt;SharePoint farms can take several forms.&amp;nbsp; Probably the most common one is the single-server farm (not to be confused with the "Simple Install", which is almost always a very bad idea).&amp;nbsp; If you're low on hardware -- or you just don't want to shell out for an extra server OS -- you can start out with all of your services on a single box and expand later as needed.&lt;/p&gt;&lt;p&gt;However, there are some roadblocks that will slow you down.&amp;nbsp; One of the most unexpected is the problem of crawling a SharePoint server from that &lt;i&gt;same &lt;/i&gt;server.&amp;nbsp; If you've tried this recently, you may have gotten this ugly message in your crawl logs:&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;b&gt;Access is denied. Check that the Default Content Access Account
has access to this content, or add a crawl rule to crawl this content.
(The item was deleted because it was either not found or the crawler
was denied access to it.)&lt;/b&gt;&lt;/p&gt;&lt;p&gt;"Why is this happening?" you may ask, after checking to make sure that your default content access account does indeed have access.&amp;nbsp; If everything else is in order, your problem is most likely something called "loopback checking".&amp;nbsp; Apparently this is a not-so-new security feature, which prevents anyone from accessing an Integrated Authentication website while logged on to the server itself.&lt;/p&gt;&lt;p&gt;"No problem", you say; "How do I turn it off?"&lt;/p&gt;&lt;p&gt;This is where it gets weird.&lt;/p&gt;&lt;p&gt;The only documented way to disable -- or work around -- this feature is to hack the registry.&amp;nbsp; The official KB article can be found at &lt;a href="http://support.microsoft.com/kb/896861" mce_href="http://support.microsoft.com/kb/896861"&gt;http://support.microsoft.com/kb/896861&lt;/a&gt;; however, since MS tech info has a way of disappearing over time, I've included a brief overview below.&lt;/p&gt;&lt;p&gt;Open Regedit and add a new Multi-String Value key under &lt;b class="uiterm"&gt;HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa\MSV1_0. &lt;/b&gt;&lt;span class="userInput"&gt;Name it &lt;b&gt;BackConnectionHostNames&lt;/b&gt;; this will be "white list" for domain names that can be explored by the local server.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Once your new key is created, simply add in all of the URLs that your crawler will need to hit on this machine.&amp;nbsp; Don't add protocols (http, etc); just feed it machine names and domain names as necessary.&lt;/p&gt;&lt;p&gt;That's all the configuration you need.&amp;nbsp; The KB article tells you to restart the IISAdmin service, but I had to do a full iisreset (remember to run as Administrator) before the changes took effect.&lt;/p&gt;&lt;p&gt;Obviously there should be a better way to deal with this than changing registry values, but you dance with whoever brought you.&amp;nbsp; Don't forget to add this to your disaster recovery plan; even the farm-level "everything" backup doesn't cover registry entries, so you'll need to keep track of it somewhere else. &lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7085141" width="1" height="1"&gt;</content><author><name>PeterBrunone</name><uri>http://weblogs.asp.net/members/PeterBrunone.aspx</uri></author><category term="Search" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Search/default.aspx" /><category term="Sharepoint" scheme="http://weblogs.asp.net/peterbrunone/archive/tags/Sharepoint/default.aspx" /></entry></feed>