The Next Home of Chris Chapman's Free Thoughts on Agile, .NET, SharePoint, what-have-you, whatnot. 
Page 1 of 9 in the sharepoint category Next Page
# Wednesday, December 02, 2009

Missed this one – on November 19/09, Microsoft launched a new TechNet site, Update Center for Microsoft Office, Office Servers and Related Products, that consolidates the hitherto somewhat scattered updates for their Office and Office Server stack.  It now provides an up-to-the-minute dashboard of the latest released service packs and security updates – with RSS feeds, of course.

Previously, a really reliable source for this kind of info was the SharePoint Product Team’s blog (still is), but their content, esp. around service packs, hasn’t been consistently tagged of late which can lead to some confusion.  I’d recommend keeping both sites in your pocket so you can get a good overview of the current patch state for the stack.

MSFT_UpdateCenter

Wednesday, December 02, 2009 10:12:29 PM (Eastern Standard Time, UTC-05:00)  #    Comments [0] -
better practices | governance | sharepoint | sharepoint2010

# Friday, November 27, 2009

Recently, I was asked to make a return visit to a customer for whom I had built a customized SharePoint web app to do “refresher” round of knowledge transfer to folks who would be entrusted with support and deployment.  It was only for an hour, and in that time I did a soup-to-nuts flyby of the highlights along with some deep-dives into code when asked about particular features.

While describing the schema for an external database we’re using to gather data, one of the attendees asked me why I opted for a single flat-file and not a series of relational tables, etc. as this would alleviate “maintenance headaches” down the road.

I reminded the fellow of the theme (which I had explained in a prior session) that guided my development on this solution :  The simplest thing that worksUsing this as a “knothole” test, I triaged and pared features and design down to keep the project achievable within the 4.5 week timeframe I was alotted.  Had I chosen to modify the schema as he suggested, I’d actually have complicated my solution on the reporting end, which uses a series of pivot charts in Excel connected to the datastore.

(I should also hasten to mention that another influence on my adherence to simplicity for this project was the failure of a similar, prior solution developed by another consultant that ended up gutted and a shadow of its former self because the customer’s support team found it “too complex” and failed to perform as advertised.)

This episode brought to mind a couple of the rules of Unix design philosophy:

2. Rule of Clarity:  Clarity is better than cleverness.

6. Rule of Parsimony:  Write a big program only when it is clear by demonstration that nothing else will do.

Beyond the example of the simple, flat schema for the data store, I employed these rules throughout my design and development of the solution, leveraging as much OOTB functionality from SharePoint as I could and only treading into custom code where I couldn’t avoid it – and even then, using low-impact techniques.

Where I couldn’t build functionality in a reasonable amount of time, I recommended purchasing pre-built web parts.  Where I couldn’t find ready-made web parts for a report user interface, I built one using client-side techniques (HTML + jQuery + AJAX + SharePoint web services) that avoided creating heavy-weight, server-side code.  Where we needed adhoc reporting capabilities because the customer was unsure of how they wanted to drill into data, I recommended using Excel with a SQL connection instead of SQL Server Reporting Services.

Now, I didn’t come to these solutions immediately;  in fact, as I know from years of experience, good design emerges iteratively.  No amount of clever Big Design Up-Front planning ever yields this quality of results.  In-line with just about every engagement I’ve undertaken within MCS, had I stuck to the original plan, I’d have delivered a solution that would have been complex and substantially off-the-mark.  However, by breaking my time down into weekly iterations, I was able (with the customer’s guidance) to zero-in on the highest value features they needed while making key compromises with their blessing.

Thus, a fundamental tool for communicating these design decisions to the customer and garnering their support were my weekly demonstrations each Friday where they could see the working solution come to life and have direct input:  “Yes, I like this;  no, that totally misunderstands what that number is for;  I am disappointed we can’t do this other thing, but I now understand why – maybe we can look at this for v2.00”.

In this way I was able to enforce the Rules of Clarity and Parsimony:  “The simplest thing that works.”

Friday, November 27, 2009 12:38:24 PM (Eastern Standard Time, UTC-05:00)  #    Comments [0] -
better practices | scrum | sharepoint

# Wednesday, November 11, 2009

A quick reminder:  Say you have a SharePoint Survey List in a site that you want to populate using a console application.  Further, say that said Survey List has an Event Receiver attached to it that needs to pick up settings from the web.config file for the host web app – let’s say a connection string.

You run your console application and notice that nothing is happening – well, something is happening, just not what you intended.  A quick look in the Event Log reveals a bizarre error indicating that an object reference isn’t instantiated and it appears to be originating several lines of code before you make a call to the ConfigurationManager thus:

_connectionString = ConfigurationManager.ConnectionStrings[SQL_CONNECTION_STRING_NAME].ConnectionString;

The line that that is generating the error has nothing whatsoever to do with this line.  It is a puzzling sort of puzzle.

You decide to check first principles and see if you can trigger the event receiver by hitting the list in the browser.  Yup:  Works fine.  So what gives?

Then you remember:  Your console app isn’t running in the same context as the browser app.  Of course it can’t find the <connectionStrings> element – it doesn’t exist as far as it’s concerned.  The called code in the Event Receiver is running blind!

<foreheadSlap> Simply add a {nameOfConsoleApp}.exe.config file local to the console .exe file and stash the configuration settings from the web.config that the called code needs to find. </foreheadSlap>

I knew this, you know.  I was just not thinking clearly while debugging.

Wednesday, November 11, 2009 12:42:58 AM (Eastern Standard Time, UTC-05:00)  #    Comments [0] -
.net | asp.net | better practices | moss | sharepoint | software development

# Friday, June 19, 2009

I’ve been away from this blog for several long months for some “good” reasons:

  • Busy, busy, busy.  From February to just recently, I’ve been working on some demanding projects (in the sense of time, not intellect) in my role as an MCS consultant with Microsoft;
  • Loss of my technical “muse” – I’ve seen… stuff, man.  And it wasn’t pretty.
  • Nothing exceptional to write about given the first two points.

So why return?  To get back into the groove and find my muse once more – if she exists!  First, some housekeeping notes:

For Recruiters/Headhunters:

  • Thank you for downloading my resume (which I know is out-of-date) and for contacting me from around the world (I’m thinking especially of the guys from Ireland, the UK, USA and yes, you too India!);
  • Please note that I am currently employed as a SharePoint Consultant with Microsoft Consulting Services Canada (MCS), and for all the warts, it really is a good gig that I’m not likely to give up any time soon;
  • Also, while I do thank you for your interest, my days of gambling a low salary for stock options in a “startup” are well-past me – I’m flattered, and I’d love to help, but really:  I’ve worked enough Bataan Death March projects to last a lifetime.

For Everyone Else:

  • I’m going to start cranking out some writings based on my recent SharePoint projects, which will include channelling an old acqaintance, SharePoint MVP Paul Culmsee, about what I’m seeing in organizations who are deploying SharePoint and why, despite the best of intentions and lots of dollars, are setting themselves up for failure.  The corollary to this, of course, is what you can do to avoid similar pitfalls.
  • I’m also going to, where I can, begin writing about what’s coming for the next release of SharePoint, Microsoft’s excellent Software + Services strategy (which moves the flagship products into the cloud and offering them on a subscription basis), and how you can ensure that your existing deployments can move smoothly when the time comes.

Stay tuned.

Friday, June 19, 2009 11:51:52 AM (Eastern Daylight Time, UTC-04:00)  #    Comments [2] -
announcement | moss | sharepoint

# Thursday, January 22, 2009

It seems that SharePoint 2007 is enjoying a mini-Renaissance right now thanks to innovative client-side “hacks” using the lightweight, open source Javascript library, jQuery.  jQuery’s strength and popularity is built on how incredibly easy it is to use to manipulate DOM elements with very few lines of code.

For example, take a look over at EndUserSharePoint: Paul Grenier has released a whack of posts on how to add some cool features to SharePoint using jQuery:

So, inspired by Paul’s great work, here’s my offering on how to mod-up the SharePoint wiki toolbar with your own links or controls using jQuery:

Jquery_custom_wiki_link

This is really easy to pull off:

  1. First, visit the jQuery website and get the minimized (ie. compressed) version of the library – i’m using version 1.3 here.  Store this in a document library within the site or wherever it is easy to access.
  2. Add a Content Editor Web Part (CEWP) to the bottom of the page by opening it in Edit Mode (Site Actions menu); open the Modify Settings tool pane and from this, the Source Editor.
  3. Paste in the following code:

    <script src="https://your.sharepoint.site/Scripts/jquery-1.3.min.js" type="text/javascript"></script>

    <script type="text/javascript">

     

    // Wait for the DOM to load before we execute...

    $(function() {

     

     // make copies of the layout cells for the wiki toolbar

     var $tdSeparator = $("table.ms-wikitoolbar tbody tr td.ms-separator:first").clone();

     var $tdToolbar = $("table.ms-wikitoolbar tbody tr td.ms-toolbar:first").clone();

     var $tdLastCell = $("table.ms-wikitoolbar tbody tr td.ms-toolbar[width]:last").clone();

     var $parent = $("table.ms-wikitoolbar tbody tr td.ms-toolbar[width]:last").parent();

     

     // remove the last TD element (padding)

     $("table.ms-wikitoolbar tbody tr td.ms-toolbar[width]:last").remove();

     

     // now build a link

     var $select = "<a href='#' class='ms-toolbar'>Wiki Pages<a>";

     

     // add a separator pipe, append the link and then the padding

     $parent.append($tdSeparator).append("<td class='ms-toolbar' nowrap>" +

       $select + "</td>").append($tdLastCell);

     

    });

     

    </script>

  4. Save and close!

As you can see, this is a really low-cost way to modify the SharePoint UI:  There’s no hassling with the .aspx layout page in the ‘12’ hive, no messing about with SharePoint Designer – just some simple Javascript, and even then it’s minimal.

Now, I do imagine if you’ve no prior experience with jQuery you may be wondering what the hell is going on up there – the best way to think of it is akin to regular expressions – it’s all about walking the DOM and finding what you want to modify.  jQuery’s notation makes this easy to accomplish and masks a lot of the complexity/verbosity of equivalent lines of code.  This said, you may want to look over Paul’s examples and the jQuery online documentation to get a handle on how to use it.

Enjoy…

Tags:
Thursday, January 22, 2009 4:01:42 PM (Eastern Standard Time, UTC-05:00)  #    Comments [0] -
moss | sharepoint

About Me
I am a Toronto-based software consultant specializing in SharePoint, .NET technologies and agile/iterative/lean software project management practices. Currently, I am employed by Microsoft Consulting Services (MCS) Canada as an Application Development and Information Worker Consultant, focusing on delivering guidance and subject matter expertise to enterprise customers who have or are in the process of deploying Microsoft technologies.

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

© Copyright 2010
Chris R. Chapman
Sign In
Archive
<March 2010>
SunMonTueWedThuFriSat
28123456
78910111213
14151617181920
21222324252627
28293031123
45678910
Statistics
Total Posts: 194
This Year: 2
This Month: 0
This Week: 0
Comments: 109
All Content © 2010, Chris R. Chapman
DasBlog theme 'Business' created by Christoph De Baene (delarou)