SharePoint

WSS and MOSS related
Faking SPContext–for testing only…
Keith Dahlby has a good post on creating a fake SPContext. Here’s the link and the code NOTE: This is not production safe code – use at own risk… http://solutionizing.net/20... public static SPContext FakeSPContext(SPWeb contextWeb) { // Ensure HttpContext.Current if (HttpContext.Current == null) { HttpRequest request = new HttpRequest("", web.Url, ""); HttpContext.Current = new HttpContext(request, new HttpResponse(TextWriter.Nul... } // SPContext is based on SPControl.GetContextWeb(), ......

Posted On Wednesday, September 21, 2011 5:55 PM | Comments (0)

App_offline.htm and SharePoint and wholly contained images…
The question came up today if we could use an “app_offline.htm” file along with HTML in that file that would reference images. First, I wasn’t 100% sure if the app_offline.htm would work, but it sure did. Since it’s just the Asp.net hosting process that detects the file, it circumvents loading any HttpApplications (SharePoint) beyond just serving up the HTML content. The second question was about having something more than text, specifically <img> tags. So, since the HttpHandlers are taking ......

Posted On Tuesday, June 8, 2010 5:25 PM | Comments (0)

Custom Error, 404, 401 pages in SharePoint…
In WSS 3.0/MOSS 2007 we had to resort to things like HttpModules [1] for errors, access denied, or for 404 errors updating the WebApp properties [2] Well, in 2010, thanks to Andrew Connell for pointing this out, Todd Carter blogs about what we now have in SPS 2010 here: http://todd-carter.com/post... [1] http://blogs.msdn.com/ketaa... [2] http://blogs.msdn.com/jingm... ......

Posted On Saturday, April 24, 2010 12:18 PM | Comments (0)

Make sure you copy the correct web.config…
During an installation issue, a client followed the TechNet article (http://technet.microsoft.c... and those instructions are misleading. It indicates to copy the “web.config” to the Layouts directory – what if fails to specify is it should be the “layoutsweb.config” file instead. While following the article does get you passed the issue that brought you there in the first place, you eventually end up with issues on provisioned sites that reference anything in _layouts ......

Posted On Wednesday, December 16, 2009 4:58 AM | Comments (0)

Deployment of Resource files (*.resx) to App_GlobalResources under SharePoint
This is a continuation from Deployment of Theme and Resource files Resource File Deployment (Resx) The second item was deploying Resource files to the App_GlobalResource directory present as a subdirectory under each IIS site for each SharePoint Web Application zone. Remember that you can have multiple IIS Sites for each “Logical” SharePoint Web Application. The other requirement we had was that each Web Application needed to have its own set of resource files and were to be deployed and scoped as ......

Posted On Sunday, January 31, 2010 1:45 PM | Comments (0)

Deployment of Theme and Resource files via Feature / Timer Jobs
Recently, we had a deployment scenario where we needed to deploy a custom theme and some resource files (resx) to the Farm and the Web Application zones respectively. Theme Deployment via Feature / Timer Job For the first feature, deployment of a theme, we initially went down the path assuming that we could scope the feature at Farm, and SharePoint would call the FeatureInstalled method in our Feature Receiver. Unfortunately, this all worked in development on our single machine environments. When ......

Posted On Sunday, January 31, 2010 1:33 PM | Comments (1)

Don’t get caught with long Account Names!!
This has bitten me a couple of times. This error surfaced yesterday when running a scripted install with psconfig.exe – the error that appears in the log is: LookupAccountName failed to get the SID for account <domain>\LONG AC NAME > 20 chars When setting up SharePoint, we usually have a bunch of service accounts that generally are setup by different teams that manage the Active Directory accounts – well, that’s how it should work, but that’s another story. Many times organizations will ......

Posted On Thursday, January 7, 2010 2:28 AM | Comments (0)

SharePoint 2010 and Claims Based Awareness
The industry it moving towards identity standards, and with the recent release of Windows Identity Foundation (fka Geneva), and the beta of SharePoint 2010, it’s important to take a look at the direction of how identity is being normalized into a “service” within the SharePoint object model. With SPS 2010, the SPUser object is now a claims identity. Identity management has been normalized to a approach that internally uses an STS that takes all “provider” or external STS identities, then creates ......

Posted On Monday, November 23, 2009 4:57 AM | Comments (0)

SharePoint 2007 and InfoPath 2010 Client – current install issues…
Ok, I’ve been bitten twice in the past week on this. If you have InfoPath 2010 Beta installed and you’ve also got SharePoint 2007 running, at least with the latest SP2 and October CU, you run into an issue that surfaces in the logs as follows One or more types failed to load. Please refer to the upgrade log for more details When you pull that log apart, you’ll see that it’s attempting to load a few types such as Microsoft.Office.InfoPath.S... from assembly 'Microsoft.Office.InfoPath.... ......

Posted On Tuesday, November 17, 2009 6:24 AM | Comments (0)

Cleanup your Features…

Many times, your coding, etc. SharePoint features.  You’ll code something up, deploy, activate, etc. 

Using WSP builder, while a convenient tool, it also leaves some orphans around.  It forcibly deletes the solution leaving any place it’s activate with some “broken features”.

Fortunately, there’s a tool to help you cleanup those orphans.

http://featureadmin.codeplex.com/

Posted On Wednesday, November 11, 2009 8:34 AM | Comments (0)

Minor update to the WSS Command Prompt…
Take the following and paste into a VBS file – then run. Still need to choose the Link, then set the “Run as administrator” when UAC is on… Set Shell = CreateObject("WScript.Shell") Set Env = Shell.Environment("PROCESS") DesktopPath = Shell.SpecialFolders("Deskt... Set link = Shell.CreateShortcut(Deskto... & "\WSS CMD.lnk") cssHive = Env("CommonProgramFiles") & "\Microsoft Shared\web server extensions\12" currentPath = RTrim(Replace(WScript.Scrip... WScript.ScriptName, "")) envBatFile ......

Posted On Wednesday, November 11, 2009 7:59 AM | Comments (0)

SharePoint 2010 Developer | Learn | Channel 9
Ted Pattison and Andrew Connell have a bunch of Learning SharePoint 2010 content up on Channel 9. I can say, having attended Ted’s classes in the past, he’s one of the best to learn SharePoint development from. He’s been at the forefront of getting to the reality of how to build things while working with the guidelines, rules, constraints of a “managed” platform such as SharePoint. If you get a chance take a look at these videos – even better, if you can attend in person, check out http://www.criticalpathtrai... ......

Posted On Wednesday, November 11, 2009 4:36 AM | Comments (0)

Visual Web Part Designer in Visual Studio 2010
In the October edition of MSDN Magazine, there’s a great article that does a quick rundown of building a component that can be surfaced as a Web Part via the Gallery and placed in Web Part zones on pages. The article by Steve Fox is here: Steve Fox - Visual Studio 2010 Tools for SharePoint Development – MSDN Magazine October 2009 There’s a couple very important aspect that might not be 100% clear from the title – 1st, you’re really visually designing a User Control (ASCX). So, this is really just ......

Posted On Saturday, October 3, 2009 5:26 AM | Comments (0)

Building a Mini URL Service – Part 2 – The Algorithm
Part 1 – Part 2 The first order of business is what URL shortening approach should be used to take some very long URL, which in IE7 is limited to 2,083 characters (KB208427) and provide a nice compact link. The first part of the link (protocol + server + port) is generally controlled by what domain name you can get – for me, my little demo is http://MyMiniUrl.net. The rest of the URL – the path is something in your control. Doing a search I came across a few approaches but settled on a Base 62 approach ......

Posted On Tuesday, May 5, 2009 8:22 AM | Comments (0)

Building a Mini URL Service – Part 1
This set of posts is about a "Mini URL" service that I created initially to help provide a means to automate shortening of URL's for sending in emails to users in SharePoint. If you've used SharePoint and at times you need to send a link to a List or Document item one way is to "right-click" the item (whether it's a folder, list item, or document) then if it's IE choose "Copy Shortcut". You can then just past that into an email and send over to your recipient. Recently, I also noticed that even the ......

Posted On Monday, May 4, 2009 11:15 AM | Comments (0)

Thanks Jukka – MOSS 2007 SP2 Upgrade Failure – Solution!
During an upgrade, the psconfig command fails with Failed to upgrade SharePoint Products and Technologies. An exception of type Microsoft.SharePoint.Upgrad... was thrown. Quick live search and I find on Jukka’s blog the answer: http://blogs.msdn.com/jukka... Specifically, a feature was not installed, and quickly installing using the stsadm command Jukku provides, it then works… ......

Posted On Thursday, April 30, 2009 3:49 PM | Comments (0)

SharePoint Designer is now “Free”
Get your copy now … Mentioned here: http://office.microsoft.com... Direct Link here: http://www.microsoft.com/do... Registration required… Well, almost free ......

Posted On Thursday, April 2, 2009 8:37 AM | Comments (0)

Kerberos Configuration Troubleshooting
I wanted to post about one of the best tools I’ve found for getting Kerberos properly configured and in the process getting some great HOWTO information on Kerberos, how it works, etc. When working with SharePoint, and the plan is to have your site run under Kerberos, I recommend using this tool before actually provisioning the Web App. You can do it later, but you’d have to “stop” the WSS provisioned Web App before using this tool. Why? Because the IIS site you use for testing must use the DNS name ......

Posted On Thursday, February 26, 2009 8:17 AM | Comments (1)

SharePoint learning resources.
Here are several links to some good resources: Sales http://blogs.msdn.com/share... Architect http://blogs.msdn.com/share... Developer http://blogs.msdn.com/share... Implementer http://blogs.msdn.com/share... ......

Posted On Wednesday, February 18, 2009 9:44 PM | Comments (0)

A little bit more on the issue with “Not enough storage is available to complete the operation”
OK. When the …\User Agent\Post Platform key (explained in the prior post) has too many items and the total length exceeds 260 characters, what happens is the javascript function windows.navigator.userAgent reports back as MSIE 6.0. As follows – using the http://www.fiddlertool.com/... test page: With a HTTP_USER_AGENT string exceeding 260 characters: getComponentVersion says you are running Internet Explorer 7,0,6001,18000. window.navigator.userAgent: [Mozilla/4.0 (compatible; MSIE 6.0)] window.navigator.appMinorVe... ......

Posted On Friday, January 16, 2009 5:15 PM | Comments (0)

Adding Web Parts via IE 7 and the “Not enough storage is available to complete this operation” javascript Error Message…
Recently, installed a bunch of new Windows Live components such as Messenger, etc. That update extended my HTTP_USER_AGENT string to beyond 260 characters, which unfortunately IE then, when asked via javascript, reports itself back as IE 6 – this causes the Modal dialog boxes in SharePoint for things like adding web parts to zones to report a message that “Not enough storage is available to complete this operation”. So, since this is an x64 machine, I need to trim down the string which is taken from ......

Posted On Thursday, January 15, 2009 3:38 PM | Comments (0)

Roger Lamb updates some guidance on SharePoint and Dispose…
If you’re doing WSS/MOSS development then you need to understand the implications of when to Dispose and not Dispose of your objects from the SharePoint object model. Roger Lamb has been keeping us all up to date and I’m sure there’s more forthcoming… http://blogs.msdn.com/roger... ......

Posted On Wednesday, January 14, 2009 6:38 PM | Comments (0)

Setting Navigation properties on a SharePoint (WSS) Site…
Recently, I was going through setting up some sample navigation approaches for SharePoint. The first step was in creating a bunch of Child Sites and some basic hierarchical structure. For that I used a great tool from IDevFactory called SWAT just to create some empty Team Sites. The one issue with that tool is it doesn’t allow setting a few options globally. What I wanted was to have under the Navigation options to have the “Show Subsites” enabled. In addition to a few other navigation settings. ......

Posted On Saturday, January 24, 2009 3:01 PM | Comments (0)

What’s my WSS/MOSS patch level?

For a good list on what your current farm patch level is at check out the following post:

http://www.mindsharpblogs.com/penny/articles/481.aspx

Just navigate to Central Administration –> Servers in Farm and look at the version reported.

Posted On Friday, January 16, 2009 5:36 PM | Comments (0)

Welcomed updates to VSeWSS – now x64 support
If you’ve been running x64 WSS/MOSS in development VSeWSS has been a challenge (wouldn’t install – albeit I believe the Bamboo solutions folks had some hack…) Now, the CTP of VSeWSS 1.3 has been announced SharePoint Team Blog CTP Preview of VSeWSS Key capabilities in 1.3 The extensions now install on x64 bit OS. Visual Studio 2008 and SharePoint must be already installed. Command Line Build option for TFS and MSBuild integration Separate WSP Package and Retract commands. You can now build the WSP ......

Posted On Tuesday, January 13, 2009 8:18 AM | Comments (0)

All this technology - where do I start!

One this is for sure, there's plenty of materials on getting ramped on the Microsoft stack.

We now have up on the MSDN Ramp Up center tracks for SharePoint...

Check it out:

http://msdn.microsoft.com/en-us/rampup/default.aspx

www.MyRampUp.com

Posted On Friday, November 7, 2008 5:54 PM | Comments (0)

Creating a WSS / MOSS Command Prompt on the Desktop
UPDATED: 8/6/2008 - Minor issue on Path I've built quite a few WSS / MOSS machines and one task that I always seem to do is create a simple CMD shell prompt on the desktop (quick launch, etc.) that gives me easy access to STSADM and has the path set correctly. So in the interest of saving time I've created a simple VBScript file located here as well as the full listing below Set Shell = CreateObject("WScript.Shell") Set Env = Shell.Environment("PROCESS") DesktopPath = Shell.SpecialFolders("Deskt... ......

Posted On Thursday, July 24, 2008 3:13 PM | Comments (0)

Windows Server 2008 RC1 and SharePoint

If you're installing Windows Server 2008 RC1 and expected to use WSS 3.0 or MOSS 2007 you'll need to wait until 12/11/2007...

It's blocked from running - I read somewhere it's due (WSS & MOSS SP1) December 11, 2007.

Posted On Thursday, December 6, 2007 8:28 AM | Comments (0)

SharePoint Development Tools are Severely Lacking
One thing I can say about SharePoint (WSS 3.0 & MOSS 2007)development is it sucks. The tools are weak from creating to debugging. Something that literally took about 15 minutes in straight ASP.NET took 3+ hours yesterday. So, I'm rethinking my perspective on SharePoint as an Application Platform when the applications are more complex than just managing lists or data direct in SharePoint, or Workflow involving SharePoint objects such as Lists, Documents, etc. I'm coming away from this thinking ......

Posted On Thursday, December 6, 2007 5:37 AM | Comments (3)

Branding of Sites in Windows SharePoint Services and MOSS 2007
I'm attending Ted Pattison's course on WSS 3.0 this week in Redmond and today we covered quite a bit around master pages, css, and web parts. From a prior class, Ted was shown an example or intercepting the request using plain a old ASP.NET Module to rewrite the master page directive giving a site the ability to dynamically apply branding based upon configuration across a Site and Site Collection. Here's the link to the CodePlex site that includes the solution. SuperBranding - Home It's great that ......

Posted On Tuesday, July 17, 2007 10:49 PM | Comments (0)