Archive for the ‘SharePoint 2003’ Category

IE 8.0 – First Impressions and Rendering

Unfortunately, I’m at home nursing the flu rather than living it up in Vegas at MIX08 so I’ve had to experience the fun vicariously through the thousands of blog posts, twitters, and videos of nearly every second of the event.

A big kick off revolved around the first Beta release of Internet Explorer 8.  Being adventuerous and well, not having anything else to do, I downloaded the x64 Vista version and have been hitting various web sites that I frequent to see how things look.

The IE Interface

Overall, IE 8 currently looks a LOT like IE7.  In fact, it takes a bit of hunting to find any differences what-so-ever.

The new “Favorites Bar” (or was that old) seems to be built to hold the new WebSlices, which I haven’t quite grasped yet (I don’t use eBay, sorry).

The Phishing Filter has been renamed the “Safety Filter”, which was immediately turned off.  I’m assuming Phishing was too difficult to explain (which is OK).  The concept is cool, I’m just not sure I want Microsoft being the “safe site” police.

Beyond that, I haven’t seen any other “changes”.  Let’s hope the real excitement is in the rendering.


The tout of IE8 is it’s successful passing of Acid2, a standards-based rendering assessment.  Sadly, this is just in time for Acid3, which it not only doesn’t pass (nothing passes right now), but it does worse than most other “current” browsers only scoring a 17/100.

So, what about real sites?

Here are a few of the more common sites I visit and the results:

iGoogle – Renders OK, albeit VERY slowly. and web parts require mousing over the empty boxes to display their contents.  There is also a bunch of odd spacing at the top of the Gmail web part.

GmailRenders OK, very fast.  I couldn’t find any issue with Gmail at all.

Microsoft Exchange 2003 OWAWorks great, very fast. 

Microsoft SharePoint 2003 (SPS)Works very well.  Renders extremely fast from page to page.  Mouse overs, context menus, etc. seem to work even better than in IE7.  Hah.

Microsoft SharePoint 2007 (MOSS) Works.  Still requires “accepting” the “Name ActiveX Control”, which is REALLY annoying, but the site renders just fine.  Also renders a bit slow, but that’s just MOSS2007. 😦

Weather.comWorks. A few positioning snafus, but everything is functional.  See image below.

Linkshell Fourms (built on VBulletin 3.6.8) – Works great.  The PHP-based forums work like a champ for my FFXI linkshell.  Thankfully!

Virtual Server 2005 R2’s Control PanelDoes not work.  Unfortunately, none of the menus work.  You cannot create/update/add anything or view the status of a running VM.  I can bounce back to IE7 emulation mode and it works OK.

MSDN Subscriber DownloadsSorta works.  I’m assuming the new version of this site will resolve these issues.  So far, the site “works”, but renders a bit funny when you move the frame bars around.


FFXI Auction HouseDoes not work.  The side navigation bar is covered up and inaccessible.  Without that, it’s almost impossible to browse through the site (searching for EVERYTHING gets a bit tedious). See image to the right. – Sorta sometimes works.  The functionality of the site is there, but the background and themes to the site are a bit haywire.  And updates aren’t being processed without a logout/login.  Ehh, odd.

WordPress – Does not work.  For some reason, the wp-admin console simply blanks the page out.  There’s a brief flash of it rendering, and then poof, just white.  I can View Source and see the code, refresh and see the flash, but haven’t been able to fix this one without dropping back to IE7 mode.

My Blog (Freshy Theme)Sorta works. Well, this blog doesn’t render right either.  The Search bar at the top right of the screen is covered up and missing the [Search] button.  The right-hand bar no longer trails to the end of the page, but stops at the end of the content (assuming the height:100% failure), The main body footer is now the footer to the right-hand bar.  There are a few other z-index issues here and there, but those can be fixed (I’m assuming).

My Photo Site Does not work.  Hmm, sucks.  Unfortunately, the menus doesn’t work.  Well, let me reword that, they work, but if you try to move from the Parent Menu to a Child Menu item, the menu disappears.  I’m assuming it’s a spacing issue for the mouse overs, but I’m not sure.  Ugh.

Random sites – I noticed most sites that I authenticated to, the hash out for the password turned up as an invalid character.  See below.

Things I Wish It Had

NoScript.  I really like FireFox’s NoScript plug in—especially with all the shakeup and paranoia regarding compromised accounts in FFXI.  I wish IE had something similar built directly into the browser.

Built-in support for social bookmarking.  Does anyone use Favorites or Bookmarks anymore?  I totally rely on and would LOVE to see better support for that in IE8.  I don’t want an annoying button that was put out by Yahoo, I want to open an Explorer Panel (like my Favorites) and see the heirarchy of my tags.


Well, for Beta 1, it’s not half bad.  It starts up instantly, looks clean, and appears to integrate into Windows Vista just fine.  If a few of the odd rendering snafus can be addressed (either by releasing WHY it doesn’t work or tweaks to the rendering engine in IE), I look forward to the next release.

Creating Single Sign-on Web Parts in SharePoint 2003

January 28, 2008 4 comments

Download Code (SharePoint 2003, .NET 1.1)

In our environment, we have several web applications that use forms authentication.  We wanted to, however, move past that on our SharePoint portal and pass that information directly if the user is already authenticated.  We assume that they’re authenticated if they’re on the Portal and authorized if they can see the link (controlled by audiences which are controlled by AD groups).

So, from there, we needed a general web part that we could supply an image (for the button), a bit of descriptor text, a link to the application, and a general format for passing the GUID (we use GUIDs rather than sAMAccountName, you could alter the code for either).

A SharePoint 2003 web part control is a composite control that contains labels, hyperlink controls, and image controls.  Most web parts are at a maximum 200px wide to accommodate modular design or have a height/width public property that can be set through the UI.  We’ll keep those properties in mind when creating our SSO web part.

NOTE: We’re not using the SSO functionalities of SharePoint.  Could this be done through that?  Maybe, but I’ve never tried.  If you have—I’d be interested in hearing how it compares.

Required Assemblies

The following assemblies should be used to generate the web part.

  • Microsoft.SharePoint, Version=, Culture=neutral, PublicKeyToken=71e9bce111e9429c
  • All other .NET 1.1 references, such as System.DirectoryServices, which are needed for the operation of the web part.

In addition, I’m using the WebPart template for VS 2003 (I’m running VS2003 in a VM with the SharePoint libraries copied over to the machine).

Fetching the GUID

The following code copies the current user (in the format of “domain\userName”) into the name variable.  Inside the try/catch statement, we’re connecting to Active Directory (using a delegated read-only account—the ONLY way you should be connecting for web applications) and using System.DirectoryServices to filter about by the sAMAccountName.  If an entry is found, the GUID is returned.

private void GetUserADGuid()


string name = this.Page.User.Identity.Name;

       name = name.Substring(name.IndexOf(@”\”) + 1);



              string[] adCredentialsArray =


AppSettings[“adCredentials”].Split(new char[] { ‘/’ });

              string adUserName = adCredentialsArray[0];

              string adPassword = adCredentialsArray[1];

              DirectoryEntry entry = new DirectoryEntry(“”,

adUserName, adPassword, AuthenticationTypes.Secure);

              DirectorySearcher searcher = new DirectorySearcher(entry);

              searcher.Filter =  string.Format(“(sAMAccountName={0})”, name);

              SearchResult result = searcher.FindOne();

              if (result != null)


                      _userGuid = result.GetDirectoryEntry().Guid;



       catch (Exception exception)


              this._userGuid = Guid.Empty;



Consuming the GUID and Rendering the Web Part

The next step is to use our GetUserADGuid method and render the redirection code for the web part (which will use JavaScript). 

private void BuildRedirect()


if (this._userGuid == Guid.Empty)






              string guidString;

              if (_encryptGuid)


                     guidString = this.EncryptString(







                     guidString =

string.Format(“{0}”, userGuid);



UriBuilder builder = new UriBuilder(this.LinkTarget);


string link =






       catch (Exception exception)





The Replace method on _linkTarget does the majority of the heavy lifting for this web part.  Part of the instructions to go along with this part is to include %GUID% on the SharePoint design side wherever you wish the GUID to be placed.

Such as:  http://myapplication.domain.local?uid=%GUID%

The web part would then replace %GUID% with the authenticated user’s GUID.

The EncryptString method is not included in this post (but in the code project attached) and is a simple method that encrypts (using the RijndaelManaged class in System.Security.Cryptography) the string information that is processed.

Finally, the web part overrides RenderWebPart and builds the control based on the properties specified at the web part’s design time (in SharePoint) and the results of the public properties.  When either the logo image or the link is clicked, the BuildRedirect method is executed that evaluates options, such as encryption and “new window”, and then redirects accordingly.  The method that builds the redirection link with the GUID is separated out from the actual redirection action for sake of testing.

SPS2003: Changing the Portal URL

December 10, 2007 Comments off

Fortunately, when you move your SharePoint Portal Server 2003 portal from one URL to another, the transition isn’t painful at all. The URLs are relative, so as long as /sites/mis, /sites/whatever continue to exist, the root URL doesn’t matter.  Good deal.

That is, of course, until alerts and confirmations get emailed out…

Over the weekend, thousands of our users were pummeled by emails (not uncommon) for the 90 day confirmation.  Unfortunately, all the URLs were wrong in these emails.  Bad deal for our Customer Service department—that sure didn’t make me any friends for a Monday morning.  I even brought homemade oatmeal raising cookies today.  LOL.

So, to change it, I have hunted all through the Central Administrator and other SPS tools, queried all through STSADM, and finally found the answer poking around with the API in .NET.  The Sites appear to have the URL hardcoded.  After a bit more looking, I found in the entries.

In the SPS2003 SITE database is a table called, very approprately, Sites.  One of the columns is called FullUrl.


Well, that’s not good.

While the “don’t mess with the databases” mantra has beaten me down for years, this “fix” has worked for us and worked quite well…  if it can be done with CA, PLEASE someone let me know.

This, however, can be fixed by a quick line of SQL:


SET FullUrl =

REPLACE(LTRIM(RTRIM(FullUrl)), ‘OldUrlHere’, ‘NewUrlHere’);

Restart the Portal services and you’re good to go.  The alerts generates reported the updated Url and things were nice.

Migrating SharePoint 2003 without SPSBackup

November 1, 2007 2 comments

The title of this post may not be totally accurate.  It could also be:

  • Migrating SharePoint 2003 from a Single to Farm environment.
  • Migrating SharePoint 2003 by Restoring the Portal
  • Migrating SharePoint 2003 through SQL Server.

or, my favorite:

  • Migrating SharePoint 2003 when the SharePoint Gods are angry with you.

There are numerous factors that come into play when trying to migrate SharePoint 2003.

  • Versions and subversions of SharePoint,
  • Versions and subversions of Windows Server,
  • Versions and subversions of SQL Server 2005,
  • Deployment hierarchy
  • and number of “Unexpected errors” that can occur for no real reason.

After a few days of battling topologies, obscure messages in SPSBackup, and service packs, I finally just installed clean copies of SharePoint 2003 on each of the servers; upgraded to the latest service packs, and tried a different approach—using SQL Server backups.

Backing Up

  1. Backup the “to be” migrated SharePoint databases (I had a SITE, PROF, and SERV database) to three separate .BAK files.
  2. Copy those files to your new SQL Server and restore them as SITE_Old, etc.
  3. The ConfigDb database is unnecessary.

Restoring the Portal

  1. When you’re first presented with the SharePoint Central Administrator, complete the service account information, server topology, etc.  This will recreate the ConfigDb for your new portal server.
  2. When creating a portal, change the radio button from ‘Create a portal’ to ‘Restore a portal’.
  3. You’ll be prompted for three database names: your site, user profile, and services.  Enter the names you gave them (SITE_Old, etc) from “Backing Up” Step #2.
  4. Specify your Portal’s URL and click OK.

That’s it; it’ll churn for a few minutes and recreate the portal.  If you are in a farm with multiple web servers, make sure you’ve recreated all necessary files, web parts, etc. on each server.


“Unsupported topology” in SharePoint 2003

October 2, 2007 1 comment

Okay, so we’re reupping our SharePoint 2003 environment to a better environment.  Why not MOSS 2007?  Ehh, quite honestly, because that’s politics and would make kittens cry.  But, that’s not the point of this post.

Our planned setup was:

  • Two web-front end servers, each running the web service.
  • One search server, running the search service.
  • One index server, running the indexing and job services.
  • Two SQL servers, clustered and attached to terabytes of space in the SAN.

Looked good, analyzer balked, but, according to KB887164 on Microsoft’s TechNet article, it’s a working, suggested scenario.

At the bottom of that article, it says:

Note After you follow these steps and then locate Configure Farm Topology (FarmTopologyView.aspx) on the Central Administration Web site, you may receive one or both of the following messages:

The current topology is not supported.
You selected an invalid server farm configuration.

These warnings may be safely ignored.

Yeah, well, that’s a lie. While running in an “unsupported topology,” you can’t add portal sites or do backup/restore operations.  That’s not unsupported, that’s unfunctioning.

I found an old blog post that has a thread regarding layout and that error.  The MVP helping the poster, Shane Young, responds with:

Technically it will let you setup this environment.  But then SharePoint will give you an error message telling you that you have an unsupported config.  Whenever SharePoint is displaying that error message it will not allow you to create new portals and it will not allow you to use its backup utility.  This is just how it works.

That’s just how it works, huh?  No recommendations or ideas?  Searching through Bill English’s SPS 2003 Resource Kit is of no use either.  In fact, the book has an architecutre of EXACTLY what I want in the book with no mention of issues or failures (pp. 116). 

If you keep digging (in the Resource Kit), page 282 lists the “supported” topologies.  For a large farm, it seems that there are three supported topologies:

  • small (1 all-in-one box + 1 sql source)
  • medium (2 all-in-one boxes + 1 sql source)
  • large (2–8 web boxes, 2–4 search boxes, 1–4 index boxes (plus 1 job) + 1+ sql source)

Notice that there are no in-betweens?  The medium can’t break apart the roles and the large requires a minimum of two search boxes. 

So, for now, my solution is to pull the Search box out and fall back to a hybrid of the medium configuration that seems to work.

  • 2 web + search boxes
  • 1 index + job box
  • 1 sql source

That configuration makes Backup and Restore and the portal creation tools happy, but seems like such a waste to put those search engines on the web drives when I have a server sitting here for it.

So, for those interested—unsupported messages may safely ignored as long as you’re not planning on USING your SharePoint Portal.

SPS2003 – Cannot Add To Site Directory? It’s a feature!

When trying to add a site to Site Directory (either manually or part of the Create Site routine), you click OK and it just does nothing.  By looking at Fiddler, it’s not so much it stops sending data, locks up, or anything—it just never TRIES.  After some digging, it’s a known “bug” with Microsoft: article #934229.  It’s caused by installing Windows Server 2003 SP2 to the box.  I wish someone would tell me when these things are applied… or, *gasp* use change controls.

The fix appears to be to bypass the InputButton control on the new site page and use simple JavaScript to submit the form.  The fix has been cataloged here from the newsgroups.

The summary of the proposed fix is to:

1. Open C:\Program Files\Common Files\Microsoft Shared\web server extensions\60\TEMPLATE\[LCID]\SPSSITES\LISTS\SITESLST\NewForm.aspx.  LCID == your locale identifier, it’s 1033 for US English.

2. Modify the file’s code to use a JavaScript submission rather than the standard web controls provided by SPS2003.  What we’re changing is bolded.

Original Code:

<SPSWC:InputFormButtonSection runat=”server”>
<SPSWC:InputFormButtonAtBottom ID=”ButtonOk” runat=”server”
<SPSWC:InputFormButtonAtBottom ID=”ButtonCancel” runat=”server”
TextLocId=”Page_CancelButton_Text” visible=”false” />

Updated Code:

<SPSWC:InputFormButtonSection runat=”server”>
<input type=”button” value = “      OK       “ 
onClick=”document.forms[0].submit();” />

<!— Commented Out for Workaround
<SPSWC:InputFormButtonAtBottom ID=”ButtonOk” runat=”server”

<SPSWC:InputFormButtonAtBottom ID=”ButtonCancel” runat=”server”
TextLocId=”Page_CancelButton_Text” visible=”false” />

Unfortunately, that doesn’t work.  Yes, the form submits, but custom fields, such as Category (we call it Building), does not submit—thus you have to go back into the directory, find your site, and manually edit it.  What a pain.

Keeping up with Microsoft

December 7, 2006 Comments off

We’ve been attempting to push out a shared solution for CMS and SharePoint Portal since I took this position, hmm, wow, over two years ago.  It’s not so much that it took me that long to load the software on the server, get a vision written, and get a customer base interested in the product–that was easy.  It was getting past the politics of my own department–the MIS Department.

Now, here we are in December of 2006 and MOSS 2007 is knocking on the door (it’s loaded in a test lab already) and I’ve been asked to write up the presentation and information to roll SharePoint out–SharePoint 2003.

So, a rock and an outdated place–roll out an old technology that doesn’t integrate into some of the new .NET 2.0/3.0 technologies I’m working on for other projects or wait until 2007 is feasible and chance that team technologies falls out of favor again?

That’s today’s internal debate.

Installing SPS 2003 SP2… requires SP2 already installed?

November 6, 2006 Comments off

Okay, so I’ll admit, that’s not what it says… but it took me a good couple readings to catch that SPS 2003 SP2 requires WSS SP2 to be installed.  Why?  Who the heck knows.  It’s been one of those days as I forage ahead with trying to figure out how Symantec NetBackup REALLY wants to backup and restore SharePoint Services.  The absolute path and naming that are required is insane.

Categories: SharePoint 2003

sps object model for dummies…

June 9, 2006 Comments off

Anyone out there have a list of the entire SharePoint Portal 2003 object model that is a map or something? I spent a good deal of time today trying to parse out the relative URL just to, on a whim, try it and find out it’s NAME. wtf. Title != Name, Url != Url, but Name == Url. 😦

Anyway, if you want to parse out the actual web URL (heh, the more I type it, the more it make sense to call it Name, damn you Microsoft), try the following. In my example, I’m breaking them into an array to deal with later.

foreach(SPWeb web in spCurrentWeb.Webs)
webList += web.Name.ToString();
webList += "|";
// Trim off excess |
webList = webList.Substring(0,webList.Length - 1);
// Split into array
siteArray = webList.Split('|');

And yes, I’m sure I could use an IList or something… but it’s modifying an existing webpart that used an array for entry (I’m adding where they can put in a * to grab all webs), and I’m not in the mood to recode it all.

Categories: .net 1.1, SharePoint 2003