Monday, December 22, 2008

User Experience - It Ain't Just Paint

We’ve known for a while now that Microsoft is taking User Experience seriously – Bill Buxton’s keynote at MixUK ’08 being clear testament to that – but it’s nice that they’re starting to share out the goodness so the message can be shouted out clear and loud.

In December’s MSDN magazine, Dr Charles B Kreitzberg and Ambrose Little give us the first I of a new set of columns focusing on putting usability into practice.

From the article, the facets of UX are:

Interaction Design Defines how the user interacts with the product. It specifies the behavior of the product in response to actions by the user and focuses on the product's navigation as well as the specific controls that are used.

Information Architecture Defines how information is organized and presented. Its goal is to support discoverability and usability.

User Research The process of studying users in order to develop a design that meets their needs, capabilities, and preferences. The methods are varied and typically employ a number of interview techniques along with observation. User logs and secondary sources are also used. Surveys and focus groups can also be used although many UX designers avoid them.

Visual Design The graphic treatment of the UI. Visual designers may be graphic artists rather than UX designers. While visual excitement is important, it is also essential that the visual design does not impair readability or usability.

Usability Testing The process of observing users performing specific tasks on a prototype or mock-up of the UI. Traditionally, usability testing was performed in a lab with observers behind a one-way mirror. However, increasingly, usability tests use webcast technology.

I’m really looking forward to the rest of this series – if only there was an RSS feed for it!

Usability In Practice :

Not a lot of people know that #1: ESENT

Well actually, probably a lot of people *do* know about ESENT, but it was new to me today!

I found a link through to a .Net API for ESENT via a MSDN post this morning, and was curious as to what on earth ESENT actually is – and it turns out to be a rather interesting piece of Microsoft technology.

From the Wikipedia entry here:

The Extensible Storage Engine (ESE), also known as JET Blue, is an Indexed Sequential Access Method (ISAM) data storage technology from Microsoft. ESE is notably a core of Microsoft Exchange Server and Active Directory.

The MSDN entry goes in to more detail and links to the reference, and there’s a good introductory blog entry on the WindowsSDK blog. You have to wonder whether this might be a useful technology for offline enabling applications – so my next bit of research has to be whether Sync Services supports it.

Time to Google…

Microsoft ESE :

Managed API for ESENT :

Silverlight controls coming of age...

For me, Silverlight has never been about rich media, so much as rich applications. So the announcement and release of Silverlight 2 was a turning point. Prior to that, Silverlight had effectively no controls – meaning no useful controls for building line of business applications.

Today though, I came across a nice posting (in Italian) by Pietro Brambati that pointed to samples pages for both the intrinsic Silverlight 2.0 controls, and for the Silverlight Control Toolkit.

I love these kinds of mini-sites – they demonstrate the controls so much better than a textual description can, and handily give you a test harness as well. We use a “sample” ourselves when developing custom controls.

Italian introduction :

Silverlight 2.0 Controls Sample :

Silverlight Control Toolkit Sample :

Thursday, December 11, 2008

Top Tip: Rooted Views

In this VSJ article, Neal Ford highlights some quick tips and tricks for increasing your productivity.

One of the more interesting ones was that of improving your “focus” as a developer by using a feature of Windows Explorer that I’d never heard of – rooted views. All you need to do is start Windows Explorer with a couple of extra parameters, and the tree-view will appear to be rooted wherever you specify. So rooting your explorer view to the root of your projects’ source code will focus your attention on the files you should be working on rather than all the other guff in your computer.

Here’s how – just run (start->run)

explorer /e,/root,c:\myprojects\project1\source

which will give you an explorer folder rooted at the source folder for your project.

You can also create a shortcut (right-click on the desktop and select new->shortcut) with the above command as the target – put this shortcut on your start menu, desktop, dock, etc for fast focused access to your project folder.

Developer productivity Tips:

Wednesday, December 03, 2008

I know I've been quiet...

Busy with paying work and all in the run up to Xmas…

But three postings on piqued my interest this morning.

The first two are by Jon Skeet, and cover what Iterators are, and how to use them to auto-generate state machines. Really interesting stuff as it gives a great deep-dive into the IL code that’s being generated and what that can mean in terms of the code that actually gets executed.

The third post is by Mark Smith, and provides a good worked examination of the how to create extensible applications with the Managed Add-In Framework. Not to be confused with the Managed Extensibility Framework, which is more about dynamic composition, this is a well-structured mechanism for handling plug-ins. Another one for me to get my head around, I guess.

This evening tho’, I’m off to the screenedit session at the Circle in Manchester for UX themed sessions sponsored by Microsoft. See you there.


Iterators, Part 1:

Iterators, part 2:


Wednesday, October 22, 2008

I'm off to DDD - are you?

Well, they opened up registration this morning, and I had to jump on it fast to ensure I get a place… That’s done, so now I can safely blog about it!

Developer! Developer! Developer! is a UK development community event that’s hosted by Microsoft at their Reading campus. The next event – DDD7, is on Saturday 22nd November.

The agenda looks really good – especially Phil & Dave’s “ASP.Net 4.0 – Top Secret” session, but it looks like there’s something for everyone there. Other potential highlights (for me, at least), include Mike Hadlow’s “Using an Inversion of Control Container in a real world application” and “Toby Henderson’s “How to develop .Net on Linux using Ubuntu”.

They just need to set up the twitter feed, the facebook event and the backnetwork now!

Get in quick!

Wednesday, October 15, 2008

You can't stop the light (redux).

Loads more Silverlight goodness today too.

Robin MestrĂ© has posted no less than four three-part series on why Developers, Designers , Marketing types and Application Architects should look at Silverlight. The posts are very much brochure-style, but they do give an excellent overview of the capabilities of the Silverlight platform – plenty of pictures to help you sell the technology to your managers.

Shawn Burke notes the release of Silverlight 2, but more interestingly give a teaser as to the state of play with the Silverlight Toolkit – due for a first preview release at PDC. The screenshot shows just how cool these controls are going to be.

On the WPF SDK Blog, Jim Galasyn points to the revised Silverlight 2 documentation now available on MSDN.

Finally, Scott Morrison has posted about what I think is one of the most exciting controls released as part of Silverlight 2 RTW – the DataGrid. This control will be making a number of 3rd party control manufacturers sweat – it’s already VERY fully featured, as Scott#’s post shows. In a follow-up, he also shows how to use the Frozen Columns feature – damn handy.

Silverlight Toolkit:


DataGrid Features:

Frozen Columns:

Tuesday, October 14, 2008

You can't stop the light

(was "Busy day at Silverlight Central" - don't ask!)

Yep – today the Microsoft Blogosphere has been buzzing with the news that Silverlight 2.0 has Released to the Web (RTW). Congrats to the Silverlight team on that – I was expecting the release to be closer (if not DURING) the PDC.

Of course ScottGu is the authoritative source as always, but I lost count of the MSDN blog posts today that reposted the news - now all I’ve got to do is un-install the RC0 bits and install the RTW bits before I can compile up code that will be shippable. Well, it will probably be shippable as soon as the CUI and Controls teams update their control libraries!

Interestingly, Ronan Geraghty went in a slightly different direction – pointing to a set of Silverlight tooling for Eclipse. This is good, because it gives an alternative tooling for Silverlight, and one that’s in use by a load of Java developers out there. Whilst it’s Windows only at the moment, it’s roadmap does include support for “Other OS” – so it probably won’t be long before that same tooling will allow for Silverlight / Moonlight development on Linux. Good times!

Scott shows us the light:

Eclipsing the light:

Wednesday, October 08, 2008

New! Atomic Memory will wash your concurrency grime away!

I’ve kind of being expecting this to rear its head, so it’s gratifying to spot that the Transactional Memory team at Microsoft are starting a blog.

This follows on from the presentation that Simon Peyton Jones made in the final Sneak Peeks session at Mix UK ’07 – and whilst they “are not working on a product release at this time” it can only be a matter of time. It’s also nice to see another part of DevDiv opening up and gathering opinion as part of their development process.

Read about it (atomically):

Monday, October 06, 2008

REMIX UK Sessions on the Web

Well, it took a while, but at last all the sessions from ReMix UK '08 are online – time to catch up on all the sessions you couldn't get to (and maybe see if you can spot yourself in the audience for those you were at).

"Get 'em while they're luke!":

(thanks to Mike Taulty for pointing this out in this posting)

Monday, September 29, 2008

Who'd have ever thought it...

ScottGu’s been at it again – this time, however, he’s announcing something quite unusual for Microsoft – shipping an open source toolset as part of Visual Studio in preference to creating a proprietary equivalent. To quote his posting:

I'm excited today to announce that Microsoft will be shipping jQuery with Visual Studio going forward.  We will distribute the jQuery JavaScript library as-is, and will not be forking or changing the source from the main jQuery branch.  The files will continue to use and ship under the existing jQuery MIT license.”

This is a big win – jQuery is a great framework for client-side AJAX, with a huge community behind it – and it’s also an extremely pragmatic approach – why re-invent the wheel again?

Kudos then to Scott and his team – and time to buy “jQuery in Action”, I think!

Get the low-down here:

Friday, September 26, 2008

Scott Guthrie - Does the man never sleep?!

Only a week ago, Scott was in the UK for ReMix UK ’08, but somehow he’s managed to slip something significant into his busy schedule:

Silverlight 2 Release Candidate 0

Yep – that’s right, RC0 is here! From his posting, there are a load of bug fixes, some breaking changes, 3 new controls and a whole new look-n-feel. Password boxes and Progress bars I can take or leave, but the ComboBox is the important one as far as getting Silverlight into enterprise applications.

There’s a slight gotcha (as well as the well documented breaking changes) in that you have to uninstall Blend 2.5 before you can install RC0 (and boy did THAT take a while) but the upgrade of Blend 2.0 to SP1 (preview) was seamless. Personally I think making Silverlight support available in Blend 2.0 was the right move – not everyone is willing to use Beta software in order to get the tooling.

Good stuff and well done to Scott & his team.

Silverlight goodness:

Friday, August 29, 2008

Design... Design... Design...

Kintan Brahmbhatt has posted a very good series of articles that make you think about the design process.

In asking “How would you design a kitchen?”, he looks at the design process, and reminds us about what has to be the key tenet of design – making sure that your specify something that is fit for task for the end user.

Kitchen magic starts here:

Freebies are always good -

Yesterday Joe Stagner posted about the free digital release of the first draft of “Data Structures and Algorithms: Annotated Reference with Example”.

It’s not complete, and rather rough in places, but it’s definitely worth a bit of your time to remind yourself about fundamental data structures and the algorithms to manipulate them. In particular, the authors highlight the complexity of each algorithm – and tell you how the algorithm will scale.

Download, Read, Internalise:

The "evil empire" embraces the source...

Lots of people have blogged about it, including The Moth, but it’s still a remarkable thing to see happen – Microsoft has released the source code to .Net 3.5 (under appropriate licenses) so you can debug into the framework itself.

Why is this important? Well, even in plain-old ASP.Net, the framework can often appear to swallow your code entirely, making it nigh-on impossible to work out why your code is broken.

Now you can trace all the way up and down the stack – and Daniel’s posted a video on how to set up VS2008 to use this to go along with the official blog.

Use the Source:

Thursday, August 28, 2008

Ani-XSS - Dang well just use it!

Vineet Batta has posted a great first article on the CISG blog, espousing the virtues of the Anti-XSS library available to ASP.Net developers.


What does Anti-XSS do? Well, plenty actually – but in particular Vineet covers how to use the SafeHtml and SafeHtmlFragment methods to sanitise rich text input from a web form. I’m looking forward to his next instalment.


Dang well use it!:

Thursday, August 21, 2008

Quick Tip: Getting at the current Page from MasterPage code-behind

I had to work this out today as I wanted to disable functionality on a master page based on the type of page it was attached to.

The MasterPage class is one that sits “beside” the Page class in ASP.Net – specifically, whilst you can access the MasterPage instance from a Page instance, there’s no property on the MasterPage to go back to the current page.

Of course, we can fix this with a helper class – here I’ve coded the sample as an extension method just for fun:

public static class MasterPageExtensions
public static Page OwningPage(this MasterPage master)
HttpContext context = HttpContext.Current;
Page page = context.Handler as Page;
return Page;

Now we call access the page from the code-behind of a master page thus:

public partial class MyMasterPage : MasterPage
private void DoSomething()
Page currentPage = this.OwningPage();


Tuesday, August 19, 2008

Nuggets of goodness

Busy day on the MSDN blogs today – as well as Mike Taulty wondering if he’s been blacklisted from TechEd (*G*), we’ve got a posting from Doug about uninstalling .Net Framework 3.5 SP1, but also serves as a very good reminder as to how the .Net framework is layered.

Next, Kirill Osenkov has a good post on understanding generics, Eric White has posts on finding duplicates using LINQ, using Lambda expressions for Event Handlers, and taking a “flat” collection and chunking it into a data structure.

Finally, Ed Glas points to a new version of Fiddler, that apart from anything else has a cool timeline visualiser.

Update: It's not over yet! Vincent Sibal has a great article covering how to use the new WPF DataGrid, and in particular it's templating options, whilst Motley & Maven have an argument about Test Automation.

Silverlight - for or against

The Register has a remarkably balanced article today giving 10 pros and 10 cons for silverlight.

Which side of the fence do you fall on?

New version of FXCop RTMs

Monday, August 18, 2008

Dragging us kicking and screaming to the WPF Grid...

Well, not quite - but today Martin Grayson posted the second part of his Silverlight 2 samples, looking in greater detail at how to build a dragable/dockable/expanding layout.

Also notable is that the first release of the WPF Toolkit – which includes a nice WPF Datagrid. Whether this impacts the commercial offerings will have to be seen.

Drag yourself here to expand your mind:

Get into the Grid here:

Streaming via WCF

Nicholas Allen’s posted a nice little article today on how to stream data over a WCF service.

The trick?

binding.TransferMode = TransferMode.StreamedResponse;

Read all about it:

Friday, August 15, 2008

Reflect on performance

Miguel de Icaza has linked to a couple of interesting articles today.

·         An in-depth explanation of how to improve performance of dynamic invocation

·         A C# port of  Google’s Protocol Buffers.

Read and reflect:


Thursday, August 14, 2008


Jeffery Palermo’s got a nice little piece on why Inversion of Control isn’t about testability – but about giving flexibility in how you design your software.

Worth a read:

Silverlight RSS

Returning multiple record sets from Oracle

When you need to retrieve complex data shapes from a database, you traditionally have been restricted to either dealing with multiple (and possibly sparse) rows per entity, or else performing multiple calls to the database and iterating the results to create your object graph.

The former CAN be pretty performant, but is a pain to implement the graph generation state-machine.

The latter suffers from the latency involved in setting up multiple database calls.

What’s needed is the ability to retrieve multiple data sets, but with just ONE database call.

SQL Server trumpets this as a feature, but Oracle’s been able to do this for a while as well. The problem has been that it’s very badly documented how you access the data through ODP.Net. Now I’ll show you how.

Let’s start by creating a stored proc that returns some data from 3 independent tables:


     p_first OUT SYS_REFCURSOR,
     p_second OUT SYS_REFCURSOR,
     p_third OUT SYS_REFCURSOR
    ) IS
         OPEN p_ first FOR
              select * from table_one;
         OPEN p_ second FOR
              select * from table_two;

         OPEN p_ third FOR
              select * from table_three;


Easy enough PL./SQL there. Let’s now retrieve the data using ODP.Net:


            OracleDatabase db = OracleDatabaseFactory.CreateDatabase ();


            OracleCommand cmd = new OracleCommand("MY_PACKAGE.PRO_GET_MULTIPLE", connection);

            cmd.CommandType = CommandType.StoredProcedure;


            OracleParameter staffTypeResult = new OracleParameter();

            staffTypeResult.ParameterName = "p_first";

            staffTypeResult.OracleDbType = OracleDbType.RefCursor;

            staffTypeResult.Direction = ParameterDirection.Output;


            OracleParameter nameTypeResult = new OracleParameter();

            nameTypeResult.ParameterName = "p_second";

            nameTypeResult.OracleDbType = OracleDbType.RefCursor;

            nameTypeResult.Direction = ParameterDirection.Output;


            OracleParameter identifierTypeResult = new OracleParameter();

            identifierTypeResult.ParameterName = "p_third";

            identifierTypeResult.OracleDbType = OracleDbType.RefCursor;

            identifierTypeResult.Direction = ParameterDirection.Output;






            //Return the filled Dataset

            DataSet dataset = db.ExecuteDataSet(cmd);


Note how we add output parameters for each of the tables the stored procedure returns? This is where the magic lies – the OracleDatabase object knows how to fill a dataset from multiple out-parameters via the ExecuteDataSet command.

Now I should point out that the OracleDatabase type is our customised Enterprise Library Data Access Block provider, so your mileage may vary with other EntLib Oracle providers.

Once you’ve got a DataSet, of course, you can iterate it in the usual manner:


            DataTable table = dataset.Tables[tableIndex];


            int index = 0;

            foreach (DataRow row in table.Rows)


                Console.Write(string.Format("{0} : {1} {2} {3}",

                    index, row[0], row[1], row[2]));





And that’s all there is too it!


Wednesday, August 13, 2008

Yield and prepare to be enumerated!

Raymond Chen has written an illuminating blog post on what *actually* happens when you write an iterator in C#.

This explains clearly what’s going on – essential for getting your head around how to use them, and in particular the yield return and yield break statements.

Start Leeks linked to it as part of his series covering yield.

Syntactic sugar:

Update: Raymond has a posted two follow-up articles.

Top Tip: Don't mix and match in webfarms

Tom details a problem on the ASP.Net Debugging blog about web farms running ASP.Net apps.

Turns out that ViewState is NOT compatible across versions of ASP.Net, or even processor architectures.

Read about it here:


Tuesday, August 12, 2008

Free ASP.Net and Winforms components

Joe Stagner links to a set of 60 free ASP.Net and Winforms controls now available from DevExpress.

Find them here:

Busy day for Microsoft...

It’s clearly a busy day for Microsoft today – just looking at the sheer volume of postings on the MSDN blogs should tell you that something’s up. But what?

Well, today is a major release day for the developer devision:

·         Visual Studio 2008 Service Pack  and the NET Framework 3.5 Service Pack 1 have both been released - good article by Somasegar here.

·         ADO.Net Data Services (formerly known as “Project Astoria” was released today too – see the Project Astoria Team Blog.

·         And finally, the Entity Framework has RTM’d as well. Their Team Blog has plenty of info.

Oh and don’t forget that SQL Server 2008 was released a few days ago as well.

Good times!


Thursday, August 07, 2008

Microsoft Sync Framework - RELEASED!

I spotted this on Eric Nelson’s blog first (thanks to his twitter feed) – the Microsoft Sync Framework has finally been released!

Why is this good – well, it SHOULD make things much easier when building occasionally connected applications. Now I just need to work out how to connect it to Oracle via my business services layer. Exciting stuff.

Read all about it:

Get the goods:


Tuesday, August 05, 2008

We're hiring!

We’re looking to hire a .Net developer to work on our next-generation product using the latest Microsoft technologies. Here’s the skinny – and if you’re interested, say you heard about the role from here!


.Net Developer reporting to the Development Manager, based in Altrincham, Cheshire.

Candidate Profile

The development department has a flat structure with small teams formed according to the needs of the developments in question. This means that we do not have fixed team leader roles but allocate responsibility based on experience and skills. An ideal candidate must:

  • Be a self motivator with the drive and enthusiasm to take on new challenges
  • Be flexible and adaptable (but disciplined) when approaching tasks
  • Work well within teams and be able to foster good working relationships
  • Be prepared to take total responsibility for the completion of tasks
  • Be a good communicator, (both written and oral) and be confident making presentations on technical subjects to co-workers
  • Be technical rather than man-management oriented

The candidate must have a minimum of 1-2 years demonstrable experience in a commercial environment developing AJAX style ASP.NET web applications in C#. Experience with Silverlight 2.0 and WPF would be a significant advantage.


To work in a team of analyst/programmers, developing and maintaining the in4tek’s next generation software products including work on customer specific portals, web services, integration projects and web applications using leading edge technologies form Microsoft and Oracle.

Approximately 80% of the time will be spent designing and developing new modules, with the remainder allocated to maintaining and enhancing existing software.

Specific activities within the role include:

  • Assisting with the production and review of User Stories and Functional Specifications
  • Working from Functional Specifications to formulate software designs and create Design Specifications
  • Working from Design Specifications to design and develop coded modules
  • Developing and executing Unit Tests to validate code.
  • Analysing and correcting software deficiencies and coding faults
  • Peer review of specifications, designs and code.

Personal development with the aim of obtaining Microsoft Certification will be encouraged.


KEY: R = required, D = desirable


Degree level qualification in IT or Business related subject


At least 1-2 years commercial .Net experience in C#


Demonstrable experience of ASP.Net 2.0/3.5 with AJAX


Experience of structured methodologies for software design and UML.


Experience of Agile methodologies of Software development


Experience of developing within a n-tier architecture


Experience of the design of n-tier architectures


Commercial Oracle and PL/SQL development experience (or equivalent SQL Server)


Database design experience (structure, relationships and triggers)


Experience of working to ISO9000 / TickIT standards


Knowledge of XML and its use in specifying and implementing software interfaces


Experience of Silverlight 2.0 and WPF


30 Essential PDF Documents

Rob Caron links to an excellent entry on the positivespace Graphic Design blog that gives “30 (actually more) Essential PDF Documents Every Designer Should Download”.

That’s bedtime reading sorted:

How often do you check in?

Eugene Zakhareyev has an interesting commentary today on how often developers check their code into source control, and the control gates that some organisations can use to ensure quality of the checked in code.

Read it now or else:


Monday, August 04, 2008

Fun with dragging panels (a.k.a. Silverlight goodness)

Martin Grayson has started blogging about the silverlight controls that the MS CUI team developed for the Patient Journey Demonstrator.

This is really good news, because it gives us an insight into how some of the most compelling UI in the market has been developed (and a leg-up on doing it ourselves).

Silverlight goodness here:



Friday, August 01, 2008

Thursday, July 31, 2008

Mike Taulty's been playing with Silverlight... Again.

More goodness from Mike Taulty - connecting Silverlight 2 (beta) to ASMX services.

Why is this important? Because it gives us a VERY quick and easy way of providing data to Silverlight from its hosting website.

One to remember for the (near) future.

Read about it:

The definition of "Done"...

Raymond Lewallen has posted an interesting piece on the definition of "Done" (aka complete, finished, good-enough-lets-just-ship-the-thing-and-worry-about-bugs-later) in terms of Agile and Lean methodologies, and in terms of the value "Done" brings to a company.

One point I agree with wholeheartedly is this:

As the people who write software, we might not always be aware of the value a product provides to its company, thus we might not understand why certain feature sets are created before others and it might not make sense to us. 

Definitely worth reading:

FW: Using client templates, part 1

Bertrand Le Roy has posted the first in a series of articles on the AJAX client templating features in the upcoming ASP.Net 4.0 release.

This will make things SO much easier for those cases where we want to get performance improvements over using UpdatePanels, but DON'T want to have to inject the markup from Javascript code.

Templating goodness here:

Onions and Architecture

We've been trying to do it all along, just not knowing it (or doing it right!)

Yesterday, Jeffery Palermo posted his second article on "Onion Architecture" - makes a LOT of sense when your application becomes not just a webapp, but an enterprise solution.


Discuss, compare, contrast - enjoy

Passwords - add salt to sage advice

Recently I've been spamming colleagues with nuggets, that should have been on here, so I'm going to start cross-posting from now on.

And with no further waffle, here's today's first nugget:

Karl Seguin has posted a neat little article on password strength - no rocket science here, but it's one of those things that's well worth re-stating to remind us as developers that we should always strive to meet or exceet best practice. And it's amazing the sites that DON'T require strong passwords.

A worthwhile read:

Thursday, January 10, 2008

knom's developer corner : Behind the Scenes of LINQ - Part 2

In his latest post on the internals of LINQ, knom finally gives a tutorial explanation of Lambda expressions and how to use them...

Either that or I was just two dumb to get it before!

Read and enjoy: knom's developer corner : Behind the Scenes of LINQ - Part 2