Free Silverlight DataGrids

One of the key controls in most applications is a datagrid. In smart client applications, you have always faced restrictions and difficulty when wanting to present data in a less ‘list style’ (using standard controls). Think of an employee table, with an image of the employee (see DevExpress example beneath).

There are commercial versions that improve things significantly, but they come at the expense of either taking a month or so out to figure how to use the control efficaciously or paying a developer to do this for you. Plus the expense of the suite of course, which usually appears vastly overpriced, but it takes genius and time to create these features with C/C++ or .NET and Windows Forms, hence the hefty price tag.

WPF and Silverlight offer  the ability to style and template controls, pretty much however you like. ASP.NET has several controls that handle this scenario in Visual Studio.


If you’re in Windows Forms you’re limited to the inflexible DataGridView or third party controls. If you are in ASP.NET and don’t know of Matt Berseth’s blog you need to correct this alarming lack of good education and check it (blog) out. There are some peaches and absolute nuggets euphemistically speaking. Matt has some technically accomplished posts, and pretty much everything he writes about is excellent. I cannot stress enough the kind of hoops you’d need to jump through to create a datagrid that looked and functioned like the super-duper listview control in ASP.NET and Matt’s example.

Scott Morrison is the new program manager for the Silverlight datagrid, and has some introductory tutorials on using this ubiquitous control. I can’t help thinking that if Microsoft had got this right with WPF and had the same availability of controls for WPF, uptake would have been far swifter. Nevertheless, we are where we are now, and some great features are already being added.

DevExpress have also announced a free datagrid that is beautiful. You can view an online demo here.

Speaking as a not quite ‘hardened’ Windows Forms developer, the sooner performance issues are sorted in WPF/Silverlight in the forthcoming Visual Studio 2008 and .NET 3.5 service pack, one begins to find it increasingly difficult, latching onto previous technologies, for the sake of reasons I have hitherto promulgated in this blog (check the windows forms category).

Silverlight. Thinking Small with Big effect

Silverlight is a cut down version of the Windows Presentation Foundation, and was formally known as Windows Presentation Foundation Everywhere (WPF/E). This cut down version includes the base class library and WPF libraries that allow .NET developers to program .NET code that can be hosted in any web browser and on any platform – Windows, Linux and Apple Macintosh.

Silverlight 1.0 was released some time ago and concentrated on media, i.e Video and Music players. There was nothing of any real interest for 50 hour a week coders. This however, has changed with a Silverlight beta 2.0, that is available which incorporates a whole host of controls. In traditional ASP.NET applications, AJAX is the most recent technology to be used to enhance user interaction with a web-page. AJAX is client focused, which means that as one browses through a web-site, one doesn’t get the page flicker and reload each time you interact with a server control or web-page. Traditionally you send a HTTPGET request to the server and it responds. AJAX uses JavaScript heavily to interact in the browser on the client machine. AJAX is essentially a hack, but it works. It gets rid of the annoying flickering, and the whole experience with the web-browser is ostensibly mellifluous.

With these two client focused technologies, Microsoft have had to shift focus to the client machine again. I started out in ASP.NET and recently returned to client development, and can truthfully say that Microsoft have put enormous resources into their web stack. Which is server based. Independent ISV’s have supplied the client stack rather well, so for a while, things trundled along nicely.

Then along came Silverlight. The principal requirement for Silverlight (like Adobe flash) is that end user download a plug-in for their browser. Microsoft have had to do some really deep thinking into what they put in and leave out. The total size at the moment is less than 5MB, so space and optimised code became a priority by default. They needed to provide a plug-in that was as full featured, but as small as possible.

One of the undoubted results of this ‘trimming-down’ exercise is the procurement of the client profile. This is such a big feature in the forthcoming .NET 3.5 service pack, and it’s all been brought about thinking as small as possible and getting the biggest result, insofar as ease of deployment.

Why Vista is perceived to be a failure

Building software is like architecture in a lot of ways. An array of engineering disciplines is required to pull off the feat of building a house or apartment block. Civil engineering is a requirement for the foundations and structure of the building. Mechanical engineering is a requirement for the materials that are structurally used. Electrical engineering is required for the wiring, not to mention all the above and more to get the supplies to and from the building site. The electrical and water supply connection to the house are likely to use Automotive engineering and Aeronautical engineering as well.

Windows Vista is built on a superfluity of computer science and engineering disciplines, all the way from in-house coding implementations, native code, to managed code. The more one delves into writing code, the more appreciation one has for the underlying operating system. This is why I love Windows, Linux and Apple Macintosh equally. Yes all have their strengths, but as software engineer and someone that adores software, I find it beyond belief, that one can ever entirely dismiss one platform for another. They are all marvellous achievements!

As a .NET developer though, my day to day focus is on Windows, and the Vista operating system is where most of my day is consumed. I have written about the lacklustre finish of this operating system, but am even more disappointed with the lack of Windows Presentation Foundation applications that are available to use on the platform. It was a decision by Microsoft to implement this new presentation layer for Windows Vista, but they have not supplied any applications for the general user to enjoy. This is why the operating system has got so much bad press, because as a general user, nothing ostensibly distinguishes XP from Vista at present. The same 100% of applications one used on XP are the same 100% of applications you use on Windows Vista. Microsoft is reluctant to update any of its successful applications, because there is no profit in it.

You have to have a very good reason to knock a house down and rebuild it. It is apparent immediately that it is very expensive, when you consider the expertise required to engineer a house. Microsoft has done this with Windows Vista and Windows Presentation Foundation. Anyone that has ever programmed Win32 or Windows Forms will tell you what a nightmare it is to try and change the appearance of a control. Take the built in calendar control for instance. It is painful. Microsoft resolved to change this, alleviate the pain and introduce WPF. The only problem is they have yet to release a major application that uses WPF, and at present, appear unlikely to do so until the next Windows 7 version. This is poisonous, because Vista will now always be seen as a failure, because it ostensibly failed to improve the application environment from XP. Most users are not silly and know this.

To put it another way, you have smashed down your old house, and built a new one (albeit with a stronger foundation, but the old one was strong enough – other houses in the same street are still standing. Like XP), and then proceeded to use the same 15 year old dirty carpets, and 10 year old gas boiler, even the sinks, shower and bathtubs are the same grotty ones you had in the previous house. You’ve also decided to paint the house exactly the same colour as previous, kept the same sofas that the dogs have chewed over the last 5 years; even the beds and bedding have remained the same. It’s the same 10 year old television (some people have flat screens now in the same street), the same phones and light fittings, the same toilets and curtains, even down to the same dustbin and doors. You have added a state of the art security system though from a company called UserAccountControl. Your washing machine and fridge have both worked for the last 15 years, so you see no reason to change to newer models because there is no benefit; it costs more, for the same functionality.

I know this analogy is rather ‘over-the-top’, but this is how your users feel, and this is why they complain, and it will only get worse for Microsoft, unless it changes the furniture for something newer, nicer, fresher, lighter and brighter. This is how people feel about software. This is the place we live in visually, more and more each day. We will never come to your dinner parties again (Vista) because your house is grotty, depressing and archaic. We also know to look out for the same furniture in Windows 7

Easing .NET Framework deployment for Windows Forms and WPF

One of the real pains with deploying a .NET 3.5 application on Windows XP (OS of choice for business) is the fact that you need to install .NET 2.0, .NET 3.0 and .NET3.5 frameworks. The first two are plus 100MB, and the last is around the 60MB mark (last time I checked). Windows Vista comes with .NET 3.0 pre-installed.

This does cause headaches for IT professionals trying to deploy a new application, or if you write a managed application distributed on the Internet, users need to download and install all the aforementioned versions before the application works. This is cumbersome, awful first impression and bad user experience when starting to use a new application.

With the forthcoming Visual Studio 2008 and .NET framework 3.5 service pack around the corner, a new feature called ‘client profile’ has been created. This, in a nutshell, removes all the extraneous libraries a client application does not use, like ASP.NET for example, and retains the most common client application libraries for both Windows Forms and Windows Presentation Foundation. A step by step tutorial is available here.


The total file size will be around 27 MB, which is tiny, and will please all the IT departments no end, that have to deploy managed applications either locally or distributed. Even if you have just a .NET 2.0 application, that is around 120MB in size, so you immediately shave off 100MB in the install. I must reiterate, that this affects both Windows Forms and Windows Presentation Foundation, and you can ease deployment for both presentation layers. You will reduce the install imprint of you application by at least 400MB and save at least 30 minutes at the start, while the client machine installs .NET 2.0 then .NET 3.0 and finally .NET 3.5 (with the restarts in the middle).

Free Dundas Charting Components in SQL Express 2008

The first Release Candidate (0) of the long awaited SQL Server 2008 has been made available on MSDN. One thing I did not know was that Microsoft purchased Dundas Charting last year, and their components are to feature in the forthcoming SQL Server 2008 release. You can find information on the changes here.

Since Dundas are the leaders in data visualisation, especially for business intelligence, this is most welcome. When you consider the cost of a single Dundas license is usually around the $700 mark, ouch! SQL Express users will not be ostracized either, as a special SQL express version with advanced services including reporting will be freely available. I hated the fact the SQL 2005 Express, or the Full version, had reporting solutions that had to be performed in IIS. This is no longer the case, and I can see some fantastic applications for this in future.

Windows 7, a case of The Emperor’s New Clothes

Popular blogger’s Long Zheng and Jeff Atwood have disquisitions on inconsistencies in the user interface of Windows Vista which are quite frankly nothing but an embarrassment to whoever was responsible for the user interface for the operating system. I would hate to be the one in charge and have to look as this plethora of user interface inconsistencies. This is in stark contrast to the Office 2007 release, which is also a huge engineering feat and a huge chunk revenue stream-wise into MSFT so much so, you really wonder if Jensen Harris would not be better in charge of Windows 7.

The fact of the matter is that there is no such thing as a new operating system as far as Windows is concerned, only the old version with some additional features. It is this that’s the most disappointing thing about Vista, insofar as it taking so long to procure, but retaining profusely ostensible relics from XP and Windows 2000. This makes the assertion that “The WOW starts now” in Vista seem like a betrayal. Long and Jeff are fastidious – it’s part of their craft – but a great deal of users feel exactly the same. They may not be able to communicate their thoughts and dismay with such written eloquence, suffice to say their derision is just as effective.

If you are going to release a new version of Windows, especially one focused on differentiated UI, then you need to practice what you preach! I for one expect pretty much all that is in Vista, plus new things like touch-screen and device oriented features to be in Windows 7, but Microsoft need to do a complete overhaul of their legacy dialogue boxes. The sad thing is it’s not a major engineering feat and does not require too many resources, just attention to detail that’s all.

Even in Office 2007, the minute you go into the tools Options in Outlook,


you face what will be a ten year old dialogue box, by the time the next version of Office comes out. It surely cannot be that difficult to ensure that all the icons used here are consistent with the rest of the user interface. And the ugly gray form, why not improve it and use the same skinning as the main application? These are the final touches needed to give an application a feeling of newness, and something Microsoft proudly almost always get wrong. Look at the treeview in office


and now compare it to the one in Vista


If only the Windows, Office and Visual Studio teams could have communicated and say “hey, tree navigation structure is important in all these applications, lets unify them”.

The long-and-the-short-of-it is that you are lumbered with the old MFC treeview that must at least be a decade old. This is why a lot of people are reluctant to move to Vista, because a lot of the applications they use for 10 hours a day, 5 days a week, are exactly the same on XP as they are on Vista. It makes no sense for a business to upgrade to Vista, especially as the nuts-and-bolts of their operations, usually lie in Office and proprietary software. No room for “The WOW starts now”, and absolutely no return on investment for retraining your IT department to support something that is the equivalent of The Emperors New Clothes.