Saturday, May 30, 2009


Microsoft Press: 50% Off All Books

To celebrate turning 1, the Australian MS Press Online Bookstore is offering 50% off all books until 30th June 2009. To receive the discount, enter this code at checkout MSPRESS1

Also, MS Press has an Amazon Price Match Promise on all books. If you find a cheaper priced book on Amazon – MS Press will match it. For more details visit the website.


Windows Vista Service Pack 2 Released

If you are running Vista and have Windows Update turned on (you do, don't you?), you will have no doubt noticed that Service Pack 2 has been released. More details here.

Monday, May 25, 2009


.NET FileHelpers

I meant to blog about Marcus Meli's time-saving FileHelpers .NET library some time ago. It's a free, open-source .NET library to read (write) delimited or fixed-length files to (from) strongly-typed arrays, or Excel, Access and SQL Server:

FileHelpers are a free and easy to use .NET library to import/export data from fixed length or delimited records in files, strings or streams.

Sunday, May 24, 2009


New Development PC Beast!

After delaying for far too long, I’ve finally replaced my aging PC with a completely new one. It’s another DIY build (where’s the fun and love in buying one off-the-shelf?), and the really great thing about DIY builds is you get to choose premium components, rather than the generic cruft present in most boxes. It’s made a large hole in my budget, but a man’s got to have a hobby! :) I was originally going to take photographs at various stages in the build (ala Jeff Atwood’s article), but ultimately I just wanted to get the thing up and running.

Here’s the Spec:

  • Intel i7 Quad Core 3.2GHz
  • Noctua SE1366 CPU Heatsink and Dual Fans
  • Asus P6T Mainboard
  • OCZ Vertex 120GB Solid State Drive (Primary Drive)
  • Western Digital 1TB hardware RAID 1 (Mirror)(Secondary Drive)
  • 12GB of Corsair Tri-Channel 1333MHz RAM
  • Asus EAH4870/HTDI/512MB Graphics Card (might buy another of these)
  • Asus DVD RW 22x Drive
  • Antec 183 Tower Case (with extra sound dampening)
  • Corsair 620W 80+ Modular Power Supply
  • Samsung 23” HD LCD

I’m running Windows 7 64bit Ultimate RC. The boot time is so fast it will make you weep as you wait 3 minutes for the PC you’re reading this on to boot up! ;)

I have to say that Windows 7 is a real joy to use. I’m really looking forward to this going RTM.

I was originally going to use one of the Western Digital 150GB 10K rpm drives as the primary hard drive (an excellent hard drive, and a firm favourite), but I decided to splash out on a Solid State Drive (SSD). These are still expensive, but over the next 18 months, the price of these will drop dramatically. [If you’ve just won the Lottery (and have $10,000+ lying around), check out the FusionIO monster SSDs].

This was a relatively expensive DIY build; to put that into context, the case plus power supply alone cost $450.00!! Despite being a great case (with great airflow, excellent sound dampening features, behind the back plane wiring etc.), the Antec 183 is very over-priced in my view. The 183 is practically identical to the previous 182 but they took out one of the very large but quiet fans, and then jacked the price up $50 (go figure)!

The only tricky bit was (as usual) installing the enormous (and I don’t use that term lightly!) heatsink with the dual push-pull fans. I don’t think there is another heatsink on the market that removes heat so effectively (great for over-clocking), but they don’t come cheaply.
The ATI chipset 4870 gave me a heart stopping moment when I booted the beast for the first time. Nothing. Nada. Zilch. I rechecked all connections, tried again. Still nothing. “Hmmm”, I thought. My nose hadn’t detected the escape of any essential “Magic Smoke”, which is always a good sign.

The Asus EAH4870, like most new PCI-Express x16 graphics cards, needs an extra 12V ATX power source due to its high current draw. Well this particular model requires not one but two extra 12V power rails! When I was installing the card, I couldn’t help notice that the 4870 had 2 6-pin 12V sockets on it. I plugged in one and thought “Surely it can’t require two...”, but it does.

(Note: one slightly odd feature of buying an expensive case is that you won’t get one of those 50 cent case speakers, which means if your motherboard does not have an onboard fault diagnostic LED display (the Asus P6T doesn’t), you won’t hear the tell tale beeps for problems with RAM, Video card etc)

All I need now is a bigger desk to accommodate a second Samsung 23” LCD monitor...

Tuesday, May 19, 2009


Visual Studio 2010 and .NET FX 4 Beta 1 ships!

Monday, May 18, 2009


Microsoft SQL Server 2008 Feature Pack, April 2009

The SQL Server 2008 Feature Pack for April 2009, a collection of stand-alone install packages that provide additional value for SQL Server 2008 has been updated:
  • Microsoft ADOMD.NET - ADOMD.NET is a Microsoft .NET Framework object model that enables developers to create client-side applications that browse metadata and query data stored in Microsoft SQL Server 2008 Analysis Services.
  • Microsoft Analysis Management Objects - Analysis Management Objects (AMO) is a .NET Framework object model that enables developers to create client-side applications to manage and administer Analysis Services objects.
  • Microsoft SQL Server 2008 Analysis Services 10.0 OLE DB Provider - The Analysis Services 10.0 OLE DB Provider is a COM component that software developers can use to create client-side applications that browse metadata and query data stored in Microsoft SQL Server 2008 Analysis Services.
  • Microsoft SQL Server 2005 Backward Compatibility Components - The SQL Server Backward Compatibility package includes the latest versions of the Data Transformation Services 2000 runtime (DTS), SQL Distributed Management Objects (SQL-DMO), Decision Support Objects (DSO), and SQL Virtual Device Interface (SQLVDI).
  • Microsoft SQL Server 2008 Command Line Utilities - The SQLCMD utility allows users to connect to, send Transact-SQL batches from, and output rowset information from SQL Server 7.0, SQL Server 2000, SQL Server 2005, and SQL Server 2008 instances.
  • SQL Server Compact 3.5 SP1 - SQL Server Compact is a free, easy-to-use embedded database engine that lets developers build robust Microsoft Windows desktop and mobile applications that run on all Windows operating systems including Windows XP, Vista, Pocket PC, and Smartphone.
  • Microsoft Connector 1.0 for SAP BI - The Microsoft Connector for SAP BI is a set of managed components for transferring data to or from an SAP NetWeaver BI version 7.0 system.
  • Microsoft SQL Server 2008 Data Mining Add-ins for Microsoft Office 2007 - Microsoft SQL Server 2008 Data Mining Add-ins for Microsoft Office 2007 enables you to take advantage of SQL Server 2008 predictive analytics in Office Excel 2007 and Office Visio 2007.
  • Microsoft SQL Server 2008 Datamining Viewer Controls - The Data Mining Web Controls Library is a set of Microsoft Windows Forms controls that enable developers to display data mining models created using Microsoft SQL Server 2008 Analysis Services in their client-side applications.
  • Microsoft SQL Server 2005 Driver for PHP - The SQL Server 2005 Driver for PHP is a PHP 5 extension that allows for accessing data in all Editions of SQL Server 2005 and SQL Server 2008 (including Express Editions) from within PHP scripts.
  • Microsoft Core XML Services (MSXML) 6.0 - Microsoft Core XML Services (MSXML) 6.0 is the latest version of the native XML processing stack.
  • Microsoft SQL Server 2005 JDBC Driver 1.2 - Java Database Connectivity (JDBC) driver for SQL Server.
  • Microsoft SQL Server 2008 Management Objects - The SQL Server Management Objects (SMO) is a .NET Framework object model that enables developers to create client-side applications to manage and administer SQL Server objects and services.
  • Microsoft OLEDB Provider for DB2 - The Microsoft OLE DB Provider for DB2 version 2.0 is a COM component for integrating vital data stored in IBM DB2 databases with new solutions based on Microsoft SQL Server 2008 Enterprise Edition and Developer Edition.
  • SQL Server Remote Blob Store - The SQL Server Remote Blob Store is a method for storing blobs of unstructured data in an external Content Addressable data store.
  • Microsoft SQL Server 2008 Native Client - Microsoft SQL Server 2008 Native Client (SQL Server Native Client) is a single dynamic-link library (DLL) containing both the SQL OLE DB provider and SQL ODBC driver. It contains run-time support for applications using native-code APIs (ODBC, OLE DB and ADO) to connect to Microsoft SQL Server 2000, 2005, or 2008.
  • Microsoft SQL Server 2008 Policies - Microsoft SQL Server 2008 Policies are examples of how you can take advantage of Policy Based Management. These policies will help you follow some of the SQL Server best practices and avoid common pitfalls.
  • Microsoft Windows PowerShell Extensions for SQL Server - The Microsoft Windows PowerShell Extensions for SQL Server includes a provider and a set of cmdlets that enable administrators and developers to build PowerShell scripts for managing instances of SQL Server.
  • Microsoft SQL Server 2008 Replication Management Objects - The Microsoft SQL Server 2008 Replication Management Objects package includes API for managing SQL Server 2008 replication objects programmatically.
  • Microsoft SQL Server 2008 Report Builder 2.0 - Microsoft SQL Server 2008 Report Builder 2.0 provides an intuitive report authoring environment for business and power users with a Microsoft Office look and feel.
  • Microsoft SQL Server 2008 Reporting Services Add-in for Microsoft SharePoint Technologies - Microsoft SQL Server 2008 Reporting Services Add-in for SharePoint Technologies allows you to take advantage of SQL Server 2008 report processing and management capabilities in SharePoint integrated mode.
  • Microsoft SQL Service Broker External Activator - This an extension of the Internal Activation feature in SQL Server 2008 and lets you move the logic for receiving and processing Service Broker messages from the Database Engine service to an application executable that runs outside the Database Engine service.
  • Microsoft SQL Server System CLR Types - The SQL Server System CLR Types package contains the components implementing the new geometry, geography, and hierarchyid types in SQL Server 2008.
  • Microsoft SQLXML 4.0 SP1 - SQLXML enables XML support for your SQL Server Database. It allows developers to bridge the gap between XML and relational data.
  • Microsoft Sync Framework - Microsoft Sync Framework is a comprehensive synchronization platform that enables collaboration and offline access for applications, services and devices. Using the Microsoft Sync Framework runtime, developers can build sync ecosystems that integrate any application, with any data from any store using any protocol over any network. Sync Services for ADO.NET is a part of the Microsoft Sync Framework. Sync Services for ADO.NET enables synchronization between ADO.NET enabled databases. For more information about the Microsoft Sync Framework, please go to Microsoft Sync Framework Developer Center.
  • Microsoft SQL Server 2008 Upgrade Advisor - Microsoft SQL Server 2008 Upgrade Advisor analyzes instances of SQL Server 2000 and SQL Server 2005 in preparation for upgrading to SQL Server 2008.

The Data-mining add-ins for Excel 2007 and the Sync Framework are definitely worth a look if you haven’t seen them before.

Sunday, May 17, 2009


Running a DevJam Community Event

What is a ‘DevJam’ Community Event?

Basically, it’s an event where the majority of (or all) speakers are local user group members. Each talk’s topic is targeted to your user group’s technology focus. Each talk should be around 5 – 10 minutes long, (depending on the number of talks you schedule). A good rule of thumb is that eight x 10 minute talks takes just under 2 hours (due to setup time between talks, and the occasional overrun, etc.).

Why are they a Good Idea?
  • Some user groups suffer from a lack of presenters, so encouraging and supporting local developers is a great way of building your local presenter pool.
  • Since the talks are short (approximately 10 minutes), people who might find preparing a complete 1 hour session a bit daunting are more likely to ‘have a go’. People often surprise themselves by being able to give a short talk without too much preparation.
  • Having a wide range of talk subject matter means you are likely to get a good level of attendance.
  • They promote face-to-face networking between local developers.
  • They are a cost effective way of running a small event, especially if you can find a few sponsors.

How do I Run a DevJam Event?

  • First decide how many talks you are going to have up front (8 works well).
  • It’s a good idea to have some worthwhile prizes as an extra incentive. Whilst winning is not the focus, it’s always nice to win something!
  • Email clear entry instructions. Check them several times for any mistakes (such as date and time) before sending.
  • Prepare about 5 – 6 weeks in advance (give people enough but not too much notice).Follow up with presenters closer to the event date.
  • Ask presenters to have their talk ready to go on a laptop, and make sure those that are not bringing their own laptop let you know in advance so one is available for them to use.
  • Ask people to save their questions until the end of all the talks. Otherwise time will quickly overrun.
  • Voting: low tech - high tech. We currently use a low tech paper voting system, where each audience member can cast one vote for each of their favourite top 3 talks.
  • Have some extra material (or perhaps some awful jokes!) on hand just in case of unforeseen circumstances (such as a laptop failing).
  • Try to provide food and refreshments so people can get together after the talks.
  • Publicise the event as widely as possible (your user group web site, INETA newsletter, regional MSDN Flash email, blogs, etc.)

What Kind of Topics?

Here are the things I highlight when asking for talk submissions for our .NET User Group:

“You can talk about any development topic but it must be between 5 – 10 minutes long.

  • Anything you’ve done.
  • Any new technology or tools you’ve investigated.
  • Any tips and tricks, or traps and pitfalls.
  • Basically anything .NET software development related!”

[I should mention that conversations with Rob Farley, some time ago, got me interested in running this style of event.]

Saturday, May 16, 2009


Perth .NET User Group: May DevJam Community Event

May’s DevJam meeting of the Perth .NET User Group was a great success. We had 50 people attend the two and a half hour event, which consisted of 8 talks from local developers on a range of topics, followed by some networking over a beer or two afterwards at ’43 Below’.

Congratulations to the winners of the top, audience voted talks, who were:
  • Graeme Foster
  • Rhys Campbell
  • Dave Gardner
Thank you to all the presenters who did a great job of both educating and entertaining, and thanks also to everyone who attended and helped out. I had many people comment on how much they enjoyed it.

And a big thank you to all the sponsors that helped to make the event a success: Excom, Microsoft, JetBrains, Beacon Technology, O’Reilly, Joe Albahari, Dave Gardner, Patrick Smacchia.

I will be running another event in December. If you are interested in taking part but not sure what to do, or how to start, feel free to drop me an email.


Wolfram|Alpha: Knowledge-Based Computing

WolframAlpha is a new online initiative from the company who created Mathematica. As the blog states it is not just a place to look up facts. Under the covers it uses Mathematica's inbuilt algorithms:
For example, if you give WolframAlpha a mathematical formula, a polynomial say, or something involving sines and cosines, it will give you back a number of useful results: a graph of the function, a list of its zeros, factored and expanded forms, etc.

Try this one: integral of e^(-t^2) dt, t=-infinity to infinity

Wednesday, May 06, 2009


C# Code Snippet: Strip All HTML Tags

A quick code snippet to strip all HTML tags using a regular expression. If you are going to call something like this often, then it might be an idea to set the RegEx.Options to Compiled.

using System.Text.RegularExpressions;


public string StripHTMLTags(string text)


return Regex.Replace(text, @"<(?:.\n)*?>", string.Empty);


Note: I'm not suggesting using this for a full blown HTML-Sanitiser. See Jeff Atwood's post and the subsequent comments. (Thanks Piers!)

Labels: , , , , ,

Monday, May 04, 2009


SQL Server Blocked Process Monitor

The SQL Server Blocked Process Monitor makes monitoring, tracking and troubleshooting SQL Server 2008 and 2005 blocked processes easy. You will no longer have to manually enable and run a trace to capture the blocked process report. In addition, the application will parse the Report XML and use the sqlhandle information contained in the report to capture the actual sqltext from the sys.dmexecsql_text DMV as the blocking occurs. There are 2 versions of the application, one targeted at SQL Server 2008, and one at SQL Server 2005. You can download from CodePlex here.

Sunday, May 03, 2009


SQL Server: Get Comma Separated List of Table Column Names

Nothing earth shatteringly new; just for my reference:

-- Get a comma separated list of a table's column names
',' + COLUMN_NAME AS [text()]
TABLE_NAME = 'TableName'
Order By Ordinal_position
), 1,1, '')

Saturday, May 02, 2009


DevJam Community Event: Thursday, May 7th

The lineup for May’s DevJam community event of the Perth .NET User Group (Thursday, 7th May), is as follows:

Tiang Cheng: Developing Software as a Service with the Google API
Graeme Foster: 'Dude, where's my memory?': Finding managed memory leaks using Windbg
Andy Dent: WPF layer-cake: C#, C++/CLI and C
Dave Gardner: NDepend
Rhys Campbell: Introduction to ASP.Net MVC
Adrian McGrath: Measuring .NET Application Performance - Application Instrumentation
Jeremy Thake: ‘What's this ReSharper all about then?’
Hadley Willan: Partial classes with LINQ-SQL

DATE: Thursday, May 7th, 5:30pm
VENUE: Excom, Ground Floor, 23 Barrack Street, Perth
COST: Free. All welcome

There are prizes for the presenters of the highest, audience voted talks (with the organisers’ decision as final in case of a tie break):

First Prize: Visual Studio 2008 Pro with MSDN Premium, worth approx. $3,500 (courtesy of Microsoft)
Second Prize: a Resharper License (courtesy of JetBrains), plus a copy of C# in a Nutshell (courtesy of Joe Albahari), plus a license for NDepend (courtesy of Patrick Smacchia).
Third Prize: a copy of Code Craft (courtesy of O’Reilly), plus a LINQPad auto-completion license (courtesy of Joe Albahari).
Audience Door Prizes: a Resharper License (courtesy of JetBrains), and a copy of Professional Visual Studio 2008 (courtesy of Dave Gardner).

In addition, the top 3 voted talks will each receive a copy of Professional Visual Studio 2008 (courtesy of Dave Gardner).

There will be pizza and refreshments provided.


Powered by Blogger