Thursday, 21 December 2006

Passed 70-536!

You may recall that I was supposed to do this exam yesterday, but there was a problem with the exam workstation, so I had to reschedule to today. It was a bit tight, as Pearson VUE wouldn't let me reschedule to next year as the voucher I used expires on 31st December.

It was reasonably tricky - a couple of the questions I just had to guess - particularly some of the stuff I don't use much, but I felt reasonably confident about most of them.

Still, it was a big relief to get to the final screen to see "You have been successful" (or words to that effect). I wanted to shout "YAY", but there were other people doing exams in the same room so I just did it silently instead :-)

I got 894 by the way.

Thursday, 14 December 2006

WinAmp plug-in for Windows Messenger, Carols at Westminster

One nice feature that my ISP Internode offer with their ADSL plans is 'free' access to numerous streaming radio services.

Until recently I've stuck with Windows Media Player (WMP), but I've found that WinAmp does have a nice feature in that it it can display the 'current song' info in the MP3 stream.

I've also just found this nifty plug-in for WinAmp that updates the "Now Playing" bit of Windows Messenger, so that people on my instant messenger contact list can see that currently I'm listening to SKY-FM's Christmas Channel! I think I'll change to another station shortly, but it is getting close to that time of year, so it isn't too bad.

While on the topic of Christmas, our band "Verandah" will be performing at Westminster School here in Adelaide on Friday night as part of their Christmas Lights Festival (I'd link to the Westminster site, but I don't want to inflict their horrible Flash-only site on you). A mix of traditional carols plus a few of our own original songs.

Code Camp Oz 2007

Mitch has announced the dates for 2007 CodeCampOz.

  • Saturday, 31st March
  • Sunday, 1st April

Almost time to start packing the car for the road-trip to Wagga!

Not sure why the earlier dates though.

Wednesday, 13 December 2006

Beta Exams for 70-541 (71-541) for Windows SharePoint Server 3.0

I've registered for the beta exam 70-541 for Windows SharePoint Server 3.0. I needed to ring up Pearson Vue as I don't think you can book the beta exams electronically.

Curiously, they didn't have "70-541" on their list, but they did have "71-541" which has the same title, and after a few tries the lady I was talking to convinced it to accept "BTA541" as the voucher/promotional code.

I have no idea if I'll pass or not, but since I'm in an exam-taking mood I thought it doesn't hurt to try, and I'll also be doing a fair bit of SharePoint stuff between now and January.

Friday, 8 December 2006

Add multiple class names to HTML elements

I was reading Mads' blog today and came across this post.

I'm amazed I didn't know this either, so I checked back to the HTML 4 spec, and sure enough, this is what it says (bold added by me):

class = cdata-list [CS]
    This attribute assigns a class name or set of class names to an element. Any number of elements may be assigned the same class name or names. Multiple class names must be separated by white space characters.

Wow, I've learned something new today! I'm now wondering about all the times when I could have used this on web pages I've worked on.

Tuesday, 5 December 2006

70-536 Exam booked

I've booked in for the "Microsoft .NET Framework 2.0 - Application Development Foundation" exam at EXCOM on December 20th.

Microsoft handed out vouchers for free exams at the Visual Studio 2005 launch last year which expire on December 31st, so I thought I better use it up before it runs out.

Resource Refactoring Tool

Resource Refactoring Tool - for C# and VB.Net, a Visual Studio.NET add-in that provides an easy way to extract strings from code and add them to resource files.


I saw this word Pebkac mentioned by one of the Mozilla developers. I think I've seen that happen a few times.

Reminds me of The IT Crowd, which even Jane found funny (and she doesn't often share the same sense of humour). Fan site with desktop wallpaper and screensaver downloads too.

Friday, 1 December 2006

Changes under the Verandah

Some sad new from last night - Michael Boundy and Kathy Pike have decide to move on to other things.

I was sure I'd blogged about the band I'm in, but searching back I can't find any posts - oh well.

I've known Kathy for a really long time. I can even remember her riding her bike in a CTA TV ad - that must have been late 1970's/early 80's! Anyway she's going to explore other things.

Michael too, has decided that it's time for him to leave. I remember being pleasantly surprised when I discovered that Michael is "The" Michael Boundy from late 80's Adelaide band Seven Stories. They had some pretty good chart success - I can certainly remember hearing their songs being played on commercial radio around that time. And now I can say I've played in a band with him!

I know I'll see Kathy around the place, and maybe bump into Michael along the way too. It's also a chance for those of us left to rethink where and what we want from the group.


Via Scott Hanselmann, Inconsolata is a promising new monospaced font that could be good for writing code in, apparently inspired by Consolas.

Thursday, 30 November 2006

A HttpModule that moves ViewState to the bottom

I came across this via LarkWare News - it's a HttpModule that moves the ViewState data in the HTML down to the bottom of the page.

The idea of doing this is that the browser then gets to render all the regular page content before it hits the ViewState blob.

Looking at the comments, there appear to be a few small problems, but it could be a useful thing to use on ViewState-heavy pages once it is more robust.

Wednesday, 29 November 2006

New Vice Chancellor for UniSA

Professor Peter Høj will take over from Professor Denise Bradley next year as the new Vice Chancellor of The University of South Australia.

Yes, that isn't a regular 'o' - it has a slash through it because Peter hails originally from Denmark, though he's been in Australia since 1987.

I'll link to the press release when it goes live.

Microsoft Ready Summit '06

I've managed to attend two of these events this year. The first was in Sydney as it coincided with family holidays in that state.

It was held at the Sydney Convention Centre (the same venue as Tech-Ed). I think there were more exhibitors in Sydney compared to Adelaide, but again the catering let Sydney down.

I didn't get to see as many sessions in Adelaide yesterday, as I also needed to get back to work to oversee our building's emergency evacuation drill (all went well I'm pleased to report).

I do think Adelaide does a much better job of putting on a seminar like this (really nice food for lunch, and they even know about dessert!) It isn't the main point of a day like this, but I do think it reflects on the quality of the venue and location. Yay Adelaide.

Remote Desktop Connection (Terminal Services Client 6.0) for Windows XP

Earlier this year, I mentioned my success in using the Remote Desktop client from the Vista beta to enable multiple monitor spanning.

I've had a few enquiries about that post, and those people will be glad to see that Microsoft have now publicly released the new version of the RDP client.

Friday, 24 November 2006

Things missing in IIS7

Some things that I've noticed are missing in IIS7 that comes with Vista.

  • WebDAV (as mentioned to me by Ben)
  • FrontPage extensions
  • The SMTP service

WebDAV is a big problem for our production web server, as we currently promote that as the way for people to edit their content.

Thursday, 23 November 2006

Blog This for Firefox 2.0 now available for Windows Live Writer

Microsoft have released a Firefox Extension (amazing in itself!) to add a Blog This button that launches Windows Live Writer.

I quite like Live Writer, particularly as it understands how to put <p> tags around paragraphs of text. All it is missing is support for Blogger Beta tags and uploading images. Hopefully these features will be coming soon.

Feature Specifications for Visual Studio and .NET Framework

Microsoft have started to publish the feature specifications for Visual Studio and .NET Framework that will be part of the next version.

Friday, 17 November 2006

Syncing with iPAQ and Vista now working

The trick is to install the "AMD64" version of the Windows Mobile Device Center (even if your CPU is not an AMD)!

Now my iPAQ is synchronising nicely again.

I'm also downloading the Vista RTM at the moment from Microsoft Connect (as a Beta Programme participant).

Windows SharePoint Services 3.0 RTW

SharePoint 3.0 has RTM'd, or should I say "Released to the Web", as Microsoft appear to be using for some of their products now.

Nothing at the moment to indicate that you can install it on Vista (which would be handy for development)

Tabbed user interfaces

I've been using Firefox for web browsing since it's first release, so I'm quite used to tabbed-browsing.

The new version of Firefox (and IE7 too) has made a small change to how tabbed browsing works - the 'close tab' button is now part of each tab.

Firefox tabs

What I've realised is that there's a difference now with how Visual Studio works - it's tabbed editing environment is like the old Firefox method - there's just one 'close' button over on the right-hand side.

Visual Studio tabs

I'm not sure which way I prefer - I can see advantages to both, but I just wish that I could make all the apps do it the same way and not be inconsistent now.

I haven't tried any of the CTPs of the next version of Visual Studio yet, but I would guess that they'll change Visual Studio to mirror tabbing in IE7 (and Firefox 2).


Looks like Microsoft, Google and and Yahoo! have been collaborating on creating a standard for a sitemap file - used by search engines to get a better idea what pages are available to be crawled and if they've been updated recently.

Wednesday, 15 November 2006

Vista RC2 64bit on my desktop

I've taken the plunge and have started using my new Dell box with Vista 64bit RC2.

Hopefully I'll get access to Vista RTM in the next week or so, then I can either install everything again, or just upgrade.

So far most things are working fine. There was a small hiccup this morning when I arranged for the IP address to be swapped over to the new box, but that seems to be resolved now.

Problems I have noticed so far are:

  • Our print server doesn't have 64bit printer drivers, so I've had to use a workaround I read about in the beta newsgroup - Create a local printer with a local port and set the port name to be the printer share name. This did the trick.
  • VMware Server refused to install. I've downloaded the beta of Virtual PC 2007 and installed that instead.
  • Symantec AntiVirus won't install on Vista 64bit. I even arranged to get hold of their beta of the next version, but it doesn't work. Hopefully they'll come out with a new beta that does work soon. I also tried the beta of Microsoft OneCare, but that doesn't support 64bit either :-( I'll just have to rely on Vista's inbuilt security for now (and be careful with email attachments)
  • I can charge my iPAQ with the USB cable, but the current release of Windows Mobile Device Center doesn't allow it to connect properly. I gather they're overdue for a newer release so maybe that will be fixed then.

At the moment, I quite like the Sidebar, but it would be nice to have a weather forecast gadget along the lines of the Firefox ForecastFox extension.

Otherwise relatively smooth sailing so far.

Thursday, 9 November 2006

Congratulations Rod

I caught up with the news last night that Rev. Rod Dyson is the new Moderator-Elect for the Uniting Church in South Australia.. Yay :-) He takes over as Moderator next November.

Another famous person I can say that I know!

Microsoft Windows Vista is RTM

Vista build 6000.16386 is RTM. Now to wait and see how long it take to be publicly available!

I bet lots of people wished that it was 16384 - a lot more geeky.

Wednesday, 8 November 2006

SQL Server Database Publishing Wizard CTP 1

This is a tool that generates the SQL for both the database schema and also to insert the data of a database.

Windows® Defender RTM

Windows Defender is a free program that helps you stay productive by protecting your computer against pop-ups, slow performance and security threats caused by spyware and other potentially unwanted software.

Windows Desktop Search 3.0 RTM

Windows Desktop Search 3.0 is now released

Windows Media Player 11 RTM

Windows Media Player 11 is released

Writing Accessible Web Applications

Microsoft have published a useful whitepaper on how to create an accessible web site/application.

Windows Mobile Network Analyzer PowerToy

Network Analyzer for Windows Mobile runs network utilities (e.g., ping and ipconfig) on a Windows Mobile powered device.

.Net Framework 3.0 RTM

.NET Framework 3.0 is now released. This makes sense as it is also part of Vista, which is due to be finished any day now.

Office 2007 is RTM

Microsoft Office 2007 is now finished. It will be good to get our hands on the final version- I've really liked the new version while running the Beta 2 preview.

Firefox 2 released

Catching up on lots of stuff that happened while I was away.. Firefox 2 is now officially released. Might need to check that all your extensions are going to work ok in the new version.

Monday, 16 October 2006

Displaying cell location on your Pocket PC Phone Edition device

Frank had also wondered about how to do this, so I found DKToday via his blog.

I then got a bit annoyed that I was getting all these pop-up notifications about what cell I was in.

Further down in the comments of Frank's post, there's a link to an article by Nick Randolph about how you can edit the registry on your Pocket PC device to tell it to not cause the cell name broadcasts to be turned into pop-up notifications.

I might see if I can write my own applet, as DKToday does seem a bit buggy.

Sunday, 15 October 2006

Phone reception for my HP IPAQ rw6828

Optus finally ported my phone number over to a new SIM from my old CDMA phone on Friday.

It all works well, but it does appear that where I live is not such a great place for mobile phone reception.

I'm wondering what options there might be. I can't find anything online about car kits or external antennas/aerials for this model, so it may mean I need to leave the phone up one end of the house that does manage to find a cell (from about 3 suburbs away!)

Or maybe I can convince Optus to install a new base station nearby.

Thursday, 12 October 2006

Active OEM/EISA Partitions confuse upgrading Windows

I've been trialling Vista on a new Dell workstation.

This machine came configured with XP Home and an "OEM Recovery" partition.

I installed Vista onto the main partition by booting from a DVD.

What I didn't realise was that it appears the machine came configured with the OEM partition as the 'active' partition.

This didn't cause a problem until I then when to upgrade the build of Vista to a newer version.

The upgrade then complained that it didn’t have enough room for the temporary files to install Windows – even though my C: had 200 Gig free!

Turns out it was probably looking at the OEM partition, which was full.

How did I resolve this? After some clues about the cause of the problem from Darrell Gorter in the Microsoft Newsgroups, I did the following:

  1. First of all, I used diskpart.exe – a command-line tool to change the active partition to C: (it’ also in XP)
  2. This isn’t the whole solution, as now if you try and reboot the machine, you’ll get a "BOOTMGR is missing" error.
  3. So you boot off the OS media (Vista DVD in this case).
  4. Set the locale/keyboard settings and then choose 'Repair your computer'.
  5. It scans your disks for installs of Windows, then click 'Next'
  6. Then click on 'Startup Repair' - this figures out that BOOTMGR is missing and puts it in the right spot.
  7. The boot manager should now be fixed and you can reboot successfully.

If I'd originally booted XP Home, I suspect this problem would have been avoided. It appears that these machines modify the active partition when they boot the installed OS. As I'd just booted clean off of the DVD, this change never took place. I imagine this problem could affect any OS that tried to install on a similarly supplied workstation.

Wednesday, 11 October 2006

Acronym support - A Windows Live Writer Plugin I'd like to see

I try to make the effort to use the <acronym> element to explain any acronyms used in my posts.

What I'd like is a plugin for Windows Live Writer that lets me select text and add surround it with <acronym> element.

If there was a acronym web service out there somewhere, then it could hook into that to source the definitions of the acronym.

Selenium and AspNetTest

I came across AspNetTest the other day while I was looking at another project on CodePlex.

I have previously used NUnitAsp for doing some unit testing of ASP.NET UI bits, but as it emulates a "noscript" browser, it isn't very good at testing the "scripty" bits - e.g. AJAX, drag/drop stuff. It has also not been developed very much in the last two years.

Anyway, AspNetTest describes itself as being built upon NUnit and Selenium Remote Control.

It appears that it provides a nice way to automate unit testing of the web UI stuff, and I've seen some demos that indicate that it should handle the tricky drag/drop and AJAX kinds of scenarios that are of interest to me.

Add variables to standard CSS stylesheets in ASP.NET

Mads implements a HttpHandler to allow C# to be embedded in CSS files so your stylesheet can be customized.

Monday, 9 October 2006

Microsoft ® Windows Mobile ® Device Center Beta 3 for Windows Vista™ (x86)

"The Microsoft ® Windows Mobile ® Device Center enables data synchronization between Windows Mobile ® powered devices and Windows Vista™"

Don't know much about this - looks a bit like it's ActiveSync for Vista.

I also got my replacement iPAQ today - with buttons that don't fall off, so we're off to a good start already :-)

Friday, 6 October 2006


Although I've been aware of Skype for quite a while, I've never had occasion to use it until now.

Our friend Jane was able to talk to her sister Ann who is now overseas, and it worked pretty well.

Not as seamless in my opinion as proper VoIP (like we use for our normal phonecalls at home), but it is still free so you can't complain about that.

My new phone

I decided to get the HP iPAQ rw6828. It arrived this week, but I'm wondering.... is it supposed to do this?

Then there's the debarcle that they didn't port my old number over to the new SIM that comes with this phone (my old phone is CDMA so didn't have a SIM).

It now looks like I'll end up with the new number on the SIM just in time to send the new phone back to be fixed. I do wonder if a drop of glue might be an easier solution.

I also noticed that Optus coverage around my house leaves a bit to be desired.

Apart from the falling off button, the technology itself looks good so far.

Wednesday, 4 October 2006

Central Splitter installed

I've finally got the C10100E Central Splitter (from MATS Systems) installed, and I'm pleased to see that the new connection speed is a reasonable amount faster than previously recorded. This also means that I've been able to relocate the modem and VoIP hardware into the storeroom (instead of sitting on the kitchen bench!)
ADSL2+ (After Central Splitter)
Upstream Downstream
SNR Margin 9.0 dB 8.5 dB
Line Attenuation 22.5 dB 33.5 dB
Speed 942,200 12,129,800

Windows Imaging Component RC1

The Windows Imaging Component (WIC) provides WIC-enabled applications to display, edit, and access metadata for any image format for which a WIC-compliant CODEC is installed.

This looks like it might be useful if you need to open or examine graphics files.

It appears that it also comes as part of .NET Framework 3.0.

Analyzing IL for unused code

Here's a useful utility that can find unused code in your compiled .NET assemblies.

Wednesday, 27 September 2006

Getting Windows Update working with a proxy server in Vista

There's a new trick to configuring the proxy information for Windows Update from within Vista. netsh is the new tool instead of proxycfg.

Wednesday, 20 September 2006

Installing Office SharePoint 2007 Beta 2 Technical Refresh

Like a few other people, I experienced a problem installing the Beta 2 Technical Refresh for Microsoft Office SharePoint Server 2007.

Everything went by the book until the "SharePoint Products and Technologies Configuration Wizard" got to the final step, when it failed with an error "could not find stored procedure 'dbo.proc_MSS_cleanup'".

The solution is outlined in this newsgroup post.

Tuesday, 19 September 2006

Which phone?

Mark mentioned to me today that I'm going to get a new mobile phone! Two possibilities are:

I'd be interested in any suggestions on those or others that I should consider (around the same price range)

Friday, 15 September 2006

Doing without SQL 2000 Enterprise Manager

I've been using the new Microsoft SQL Server Management Studio, the new administrative tool that comes with SQL 2005.

I've also kept a copy of SQL 2000 Enterprise Manager installed, because that was the only way I could edit and maintain the DTS packages we have running on our SQL 2000 boxes.

However, today I discovered that if you install the Microsoft SQL Server 2000 DTS Designer Components, which is part of the Feature Pack for Microsoft SQL Server 2005 - April 2006, then not only can you open and edit DTS packages on a 2005 server, but you can also do the same on a 2000 server.

So as far as I can tell, I don't need to run the SQL 2000 client tools anymore.

Office 2007 Beta 2 Technical Refresh

The Technical Refresh of Microsoft Office 2007 Beta 2 is now available to download. This is a patch/update for Beta 2 - you need to already have Beta 2 installed to apply these updated.

Thursday, 14 September 2006

Links for posts are not showing

In the old blog template, if a post was about one thing I'd found, I'd put a link to it and it would appear next to the title of the post.

The bad news is that it seems the new template doesn't currently support displaying this. Hopefully they'll fix that real soon. In the meantime, I'll go back to putting the link in the post itself.

For the record, this relates to what used to be called 'BlogItemUrl' in the old template language.

Blogger Beta

I've taken the plunge and migrated my blog to the new 'beta' from Blogger. Apparently everything is stored in a database now, so all changes are reflected instantly - no 'rebuild' step when posting or modifying the template.

Posts can also now have labels, which should help me to categorise things.

Hopefully everything continues to work how it used to. Let me know if something has broken.

Monday, 4 September 2006

Internet safety for kids - Online resources

Here are some of the resources mentioned in the "Internet Safety for Kids" talk: Other related links:

"Internet safety for kids" presentation for parents

I'm presenting a talk on Internet Safety for Kids on behalf of UCount Support Services at the Aberfoyle Uniting Church (42 Sunnymeade Dr, Aberfoyle Park) at 8pm on Monday, 4th September.

I've posted a separate list of links to online resources. I'll try to keep that list updated as required.

Thursday, 31 August 2006

dotTrace Profiler

"Efficient CPU profiler for hunting down performance bottlenecks in your .NET applications" - as recommended by the Joy of Code.

IE + JavaScript Performance Recommendations - Part 1

Some useful best practices for making JavaScript work well in IE (and most likely in other browsers too)

Saturday, 26 August 2006

Tech-Ed 2006 - Day 3

Friday was a pretty good day. Some good talks from Mitch on extending Team Foundation Server, and a really interesting final session on Concurrency from Joel Pobar.

The closing keynote ("locknote") was by Dr Frank Soong. He showed some really impressive image and video algorithms that Microsoft Research have been developing. Some pretty smart guys are working there I think.

Next year will be back at the Gold Coast, and I get the impression that I'm not the only one who was a bit disappointed with a few of the things this year. I'm optimistic that they'll do a much better job in Queensland in 2007.

Hopefully they can also get rid of those ridiculous barcode scanners that made us all feel like sheep when ever we entered one of the sessions.

I flew back to Adelaide this morning, and while I enjoyed the conference, it is really nice to be back home with the family again.

Thursday, 24 August 2006

Tech-Ed 2006 - Day 2

As I'm staying with family instead of a Hotel with the rest of the guys from work, I have noticed that I'm not seeing as much of the other Adelaide guys as I normally would.

Some really good presentations today. I managed to end up in four sessions that Scott Guthrie was leading. Pretty much everything I'd been hoping for. I was especially impressed that he stayed long after the specified end time for his talk about LINQ to answer questions from the audience.

I also had some nice chats with Rob today, and he kept introducing me to interesting people and offering me to fly interstate to do my IPsec and Connection Pooling talks at their user groups! I'd be happy to go, but I suspect they'd want a bit more than a 10-15 minute talk from an interstate presenter.

The low point today would have to have been the "party" night. I would have hoped that the organised would have learned from the last Brisbane conference when we got bussed off to a night-club. Tonight at least it was just a short walk from the convention centre, but why they figure 2,500 delegates would want to all cram into a pokey, noisy nightclub is beyond me. I'll admit I'm not a "clubbing" kind of guy at the best of times, and maybe a lot of people like this kind of thing. However it did seem to me that a reasonable number of people were leaving very early.

Last year was probably the best social night I've attended - at least at Movie World you could spread out a bit, plus the catering was excellent and if you wanted to go on a ride so you could throw up and enjoy the food a second time, then why not!It's just a pity they couldn't repeat the effort this year.

Tech-Ed 2006 - Day 1

The venue (Sydney Exhibition and Convention Centre) is quite good. It's a pleasant walk from Town Hall Train Station, so it is quite convenient, and the location is very pretty at Darling Harbour.

Food - In a word, "Below Average". Well that's two words, but you get the idea. I've been to quite a few Tech-Ed conferences now (missed the first one in Sydney, and the Canberra one), so I've seen how a number of different venues perform. At least they are generous in putting out a lot of the stuff, but I'm getting tired of little meat pies (served for morning teas and for lunch). Haven't they heard of cakes and slices?

Audio/Video - The Keynote was let down by the video of the presenter being really out of synch with the audio. It isn't rocket science, and it can't be the first time they've done this. I also noticed that one of the breakout rooms also had very echo-ey sound - a bit like a bathroom, which just detracts from the whole experience.

Keynote - This was by Anne Kirah - a Cultural Anthropologist who works for Microsoft MSN. She had some interesting stories to tell about how "real" users (eg. regular people) use software and how Microsoft is trying to become more "people focused", rather than "technology focused".

Apart from that, the speakers were good, and there was some interesting stuff.

Tech-Ed 2006 - Getting here

The original plan was for the family to drive over to Sydney, but my Dad ended up having a major back operation scheduled for Monday, so we thought it would be best to hang around to see how that went instead.

Fortunately, work was happy for me to fly over instead, but it has meant that our planned holiday and catching up with family in NSW will be postponed until later in the year.

The flight was good, and I'm still staying with the in-laws as originally planned, so I'm being looked after very well :-)

Wednesday, 16 August 2006

Visual Studio .NET 2003 SP1

You might argue that this is 3 years late, but at least they finally released a service pack for Visual Studio 2003.

Apparently, the service pack for 2005 is due later this year - and not before time too - while the features of the new environment are fantastic, I'm seeing it crash with alarming regularity. Not the stable development environment you would expect.

Tuesday, 15 August 2006

Windows Live Writer

A new desktop application for writing blog entries. Quite a nice WYSIWYG interface. Will be interesting to see how good the integration with Blogger is.

Wednesday, 2 August 2006


This is a .NET library that provides a nice, managed framework for interacting with IIS

Tuesday, 1 August 2006

Windows Communication Foundation Part 2: Reliable, Queued and Transacted Messaging

Dave Glover returns to Adelaide to present another talk on Windows Communication Foundation.

Thursday, 3rd August 2006, 12 noon at Santos Building

Monday, 31 July 2006

Sandcastle - July 2006 Community Technology Preview

Sandcastle is the name of the tools used internally by Microsoft to create documentation help files from managed class libraries.

Monday, 24 July 2006

First Technical Steps to managing your own business

Here's some useful info about getting your web presence up and running. I took advantage of this advice to resurrect my "Business and Consulting" website -, using ZoneEdit.

It had gone offline quite for a while after the previous free hosting through work concluded.

I'm now pointing it to an area on my ISP-provided web hosting, and I've also got some nice email address forwarding happening too (which I didn't have before).

Friday, 21 July 2006

ClustrMaps - Hit counter map shows locations of all visitors to my blog

I've added a link to ClustrMaps on my blog, to see if there really are any people who read my blog!

I heard about this from Rob Caron, and the fact that there are no dots on Adelaide makes me wonder a) am I the only one in Adelaide reading his blog or b) have they got Adelaide somewhere in the middle of Australia!

Thursday, 20 July 2006

Get organised with Solution Folders

This is a nice tip that I've already used to organise our Online Assessment solution. Now Alexis doesn't need to worry about those funny "deploy" projects - she can just find the web projects easily.

Tuesday, 18 July 2006

VB 2005 Exception Helper

A Visual Studio 2005 add-in written by Bill McCarthy that adds appropriate exception handlers to the selected code.

This add-in depends on the latest version (2.0.1) of the DevExpress DX Core library. If you had already installed the free Refactor! add-in, then you'll need to update it so that it is compatible. The links to the latest version are in this post. I think the site has "referrer" detection, so make sure you're already browsing the devexpress site before you try and download.

Tuesday, 4 July 2006

Expression June 2006 CTPs

Friday, 30 June 2006

Download details: Internet Explorer 7 Beta 3 (Windows XP SP2)

Internet Explorer 7 Beta 3 is out now.

Best Practice Analyzer for ASP.NET

"The Best Practice Analyzer ASP.NET (alpha release) is a tool that scans the configuration of an ASP.NET 2.0 application. The tool can scan against three mainline scenarios (hosted environment, production environment, or development environment) and identify problematic configuration settings in the machine.config or web.config files associated with your ASP.NET application. This is an alpha release intended to gain feedback on the tool and the configuration rules included with it."

Thursday, 29 June 2006

Remote Desktop spanning two monitors

If you participate in the Windows Vista beta program and you use Remote Desktop, then you might want to have a look at the new RDP client. There's a version for XP SP2 and 2003 SP1.

The main feature that interested me was that it now supports spanning multiple monitors. I've installed it on my XP SP2 box at home, and I can now connect to my XP SP2 box at work and have my desktop span across both of my monitors! I didn't even need to install the new client on my work box to get this either.

The resolution limit is up to 4096x2048

Sunday, 25 June 2006

Transactions and Unit Testing with NUnit (part 2)

The good news - I got the transaction unit testing code to work. Two traps that caught me out:

  1. Make sure the test fixture class inherits from the class defined in the transaction library assembly.
  2. Make sure your machine has a valid DNS entry! Turns out mine didn't as I'd reinstalled the OS a couple of months back, and our Active Directory DNS had kept the old record with a SID for the old machine - hence the new install had a different SID and wasn't allowed to update the DNS record.
    This had the effect that the remote server could not resolve my workstation to get the RPC conversation working properly.

Code analysis without buying Visual Studio Team System

If you download the Microsoft® Windows® Software Development Kit (SDK) for Beta 2 of Windows Vista and WinFX Runtime Components, then you actually get the C++ compiler that includes support for the "preFAST" /analyze code analysis feature.

Normally, you'd only get this if you purchased Visual Studio Team System for lots of $$$.

I installed it, and managed to get Mozilla Firefox compiled (just a couple of patches required - problems with the new headers in the SDK conflicting with Mozilla code).

The easiest way to analyze the code is to edit your mozconfig file and add the following:

ac_add_options --enable-optimize="-analyze"

I've uploaded a build log that includes the various warnings. Many are spurious, so the trick is to weed out the noise and find the ones that are relevant.

Wednesday, 21 June 2006

Customising Visual Studio.NET 2005 for Single and Dual Monitors

I have been using a dual-monitor setup for a couple of years now, and find it a very practial way to develop.

I also work from home, and use Remote Desktop (RDP) to connect back to my workstation at work. The problem is that RDP only works on a single screen - so when you launch Visual Studio, all the windows that were anchored on the second screen now are messed up.

The solution is to use the Import and Export Settings wizard to save two window layouts - one for a single screen and one for a dual screen. You can then load these settings to reset the window layout for the appropriate monitor.

To automate the process even further, you can create some Visual Studio Macros and assign them to a custom toolbar so that you can do it all with a single click of your mouse.

Here's my macro code that loads the two different window settings:

Sub RDPLayout()
    DTE.ExecuteCommand("Tools.ImportandExportSettings", "/import:""U:\My Documents\Visual Studio 2005\Settings\rdp.vssettings""")
End Sub
Sub DualMonitorLayout()
    DTE.ExecuteCommand("Tools.ImportandExportSettings", "/import:""U:\My Documents\Visual Studio 2005\Settings\dual monitor.vssettings""")
End Sub

Transactions and Unit Testing with NUnit

Roy Osherove has written a useful library that adds support for wrapping your unit tests inside a transaction (using MSDTC/COM+) which means that you can test your data-layer code and not worry about messing up your database.

The only problem is I can't get it working for me:-(

  1. Microsoft increased the security around using COM+ in Windows XP Service Pack 2 and Windows Server 2003 Service Pack 1
  2. The database I'm testing against is on a remote server (running 2003 SP1)

So even after reading this KB article, I still can't get it to work. The unit test just hangs, and I think it's because MSDTC is having problems of some kind.

Tuesday, 13 June 2006

Australian Story :: Dzung's Anatomy

My wife and her family are friends with the Davis family, and Carl (their son) is married to Thau (Dzung's daughter).

Sunday, 11 June 2006

View Trace.axd

Roger has written a Firefox Extension that ASP.NET developers will find very useful.

As I always say, "Anything that saves me extra keystrokes is a good thing!"

Monday, 5 June 2006

PageMethod Testamonial

Fabrice has published my testamonial about how we are using the PageMethods component with our development of an Online Assessment Tool.

Thursday, 1 June 2006

ObjectDataSource and Sorting (Part 2)

Sergio asked if I could post how I solved my problem with sorting and the ObjectDataSource control.

Here's what I did:

First of all, add a parameter to the method that is being called by the ObjectDataSource control that will be used to sort the data.

    <DataObjectMethod(DataObjectMethodType.Select)> _
    Public Shared Function GetTests(ByVal sortExpression As String) As TestInfoCollection
        If sortExpression Is Nothing Then
            Throw New ArgumentNullException("sortExpression")
        End If

It's up to you what you do with the value that is passed in. The value comes in looking like the sort bit of SQL. In my case to get things up and running I'm loading my data into a DataTable, then use a DataView to do the sorting for me - not the most efficient way but it works for now. Later on, I might pass the sort criteria down to SQL Server and let it do the sorting for me, but that will require messing with the stored procedures!

It seems like an oversight that there isn't a special attribute to prepend the sortExpression parameter so that the ObjectDataSource recognises it as special - unfortunately it just thinks it's a regular parameter and will add it to the SelectParameters part in the aspx file. You just need to remove it from there and instead make sure the SortParameterName attribute is set instead.

<asp:ObjectDataSource id="odsTests"
<asp:QueryStringParameter ConvertEmptyStringToNull="False" Name="courseId" QueryStringField="CourseId" Type="Object" />

Wednesday, 31 May 2006

Thursday, 25 May 2006

Vista Beta 2

Windows Vista Beta 2 has been released. I'm downloading it now.

If it looks stable enough then I'll consider reloading my workstation with it (Time to live dangerously!)

Tuesday, 23 May 2006

Poppa Bill

Today just after 4pm, my grandfather "Poppa Bill" passed away. It is a really sad day, though in a sense there is a sense of relief that he doesn't have to struggle with his health anymore.

One thing to hang on to is that we will meet again one day in Heaven. Tonight as we put the kids to bed, we thought about some of the things he would now be able to do again that he hadn't for a long time because of poor health - including running around, eating donuts and meat pies! (Poppa had diabetes)

He had a most remarkable life, and I will miss him a lot.

Thanks Poppa.

Monday, 22 May 2006

Using Annotations to Reduce C/C++ Code Defects

Michael Howard blogs about using the Standard Annotation Language to improve static code analysis and find more bugs (including security bugs) in your C and C++ source code. I've filed a bug to see if these annotations can be added to the Mozilla source code.

Thursday, 18 May 2006

Google Notebook

I've been using Microsoft OneNote for a few years now, and find it quite useful for storing all sorts of useful things. We're also using it at home as a way of recording recipes too, instead of having countless slips of scrap paper flying around. Now along comes Google Notebook - a free web-based service that sounds like a pretty similar idea. It only works for Firefox (and IE) at the moment.

Tuesday, 16 May 2006

Domain-Specific Language Tools: Model-Driven Development of .NET Enterprise Applications

I heard Susan Entwisle present at CodeCampOz this year, and it was quite an interesting presentation. Slightly more "academic" or "big-picture" than some of the other talks, but fascinating nonetheless.

To be honest, I'm still not certain that we could make very much use of these kinds of tools with the kind of projects we work on, but it is an interesting field to keep an eye on.

Tuesday, 9 May 2006

Prioritizing Web Usability: Jakob Nielsen's new book

Haven't read it yet, but we should be getting a copy soon. Jakob knows his stuff, and his earlier book Prioritizing Web Usability (Voices That Matter) is one of the standard references on the subject.

Monday, 8 May 2006

Extension progress

I'm pleased to say that we finally have some really good progress on the house extension.

Paul (our builder) hurt his back just after the slab was poured, so he's only just been able to return to work. As you can see, we have had a bit of rain lately so it a bit on the muddy side now.

It's all looking really good though, and it is great to finally be able to walk around and get a sense of the space and size of all the rooms.

Friday, 5 May 2006

Consolas Font Pack

The Microsoft Consolas Font Family is a set of highly legible fonts designed for ClearType.

I've blogged previously about how I enabled ClearType because it should improve productivity. I've left it on at home with the LCD monitors, but I reverted back to the standard fonts on the CRT monitors at work as it was just too fuzzy to work with.

Unless you're using ClearType on a suitable monitor, I wouldn't bother with these fonts. They don't look that great on my CRTs. I'll give them a try at home though.


Diarist - A nice PocketPC application for writing blog posts.

Thursday, 4 May 2006


The built-in unzip in Windows XP is nice to have, but for some reason it runs extremely slowly if the zip has more than a few files in it. I'm trying out "TUGZip" as it also integrates with Windows Explorer and looks like it is a bit snappier in the performance stakes. It's also freeware.

Tuesday, 2 May 2006

Monitoring ASP.NET Apps using MOM 2005

The ISTS Unit here at UniSA have begun using MOM to monitor our Windows Servers. I'm interested in whether creating management packs for our ASP.NET applications would help with monitoring and getting early warning of potential problems.

Here is some light reading to get up to speed:

Sunday, 30 April 2006

Microsoft Australia - Tech.Ed 2006

Snazzy web page too!

I'm planning to drive over with my family, so we can catch up with the in-laws and Sydney relatives at the same time.

Thursday, 27 April 2006

Notifying webmasters of penalties

Google are making it a bit easier to find out how they are indexing your site and any problems they are finding along the way.

Because I use Blogger's BlogSpot domain, I can only customise the template for the page - not add any extra files to the site. However the sitemap facility does support Atom 0.3 feeds, which my blog does have, so I've pointed it to that feed. It says it will take a few hours to update, but it will be interesting to see what it says about my blog once it is finished.

Wednesday, 26 April 2006

Sunday, 23 April 2006

Mozilla patch and CodeCampOz

Two interesting things have happened in the last couple of days - I've had another patch accepted into the Mozilla source code repository, and I've driven to Wagga Wagga with Roger, Gary and Dat to attend the 2006 CodeCamp.

The Mozilla patch fixes a problem that some users had noticed with Firefox 1.5 when they were pasting web content into Outlook 2000 plain-text emails. An unusual case, but it looks like the fix was pretty simple and didn't break the functionality for other users. The patch is checked in to the "trunk" and should make it into Firefox 2.0 - I'll try to get it into a future 1.5 update but that may be over optimistic.

The drive to Wagga went well. It's good to have Dat along on this trip (he couldn't make CodeCamp last year). So far the presentations have been really good, though I confess I (again) didn't pay attention in the BizTalk session :-)

Thursday, 20 April 2006

Design for Operations Integration Kit

This is interesting - it's a sample that generates work items in Team Foundation Server when a .NET application has application errors or performance problems.

The only problem I can see is that it apparently requires MOM on the server where the applications are deployed.

We currently just generate e-mails with the exception details and send them to the developers. Still, if the dependency on MOM could be removed then this could be useful.

SQL Server 2005 SP1

SQL Server 2005 Service Pack 1 has been released

There are also "April" releases of a number of other SQL 2005 tools:

Wednesday, 19 April 2006

Setting TFS work items to default to be unassigned

Wouldn't it be nice to have your work items in Team Foundation Server default to be "unassigned", so that it is easier to determine what jobs are being worked on and what are unallocated?

Well it turns out this is possible.

First of all, you need to export the work item definitions that you want to customise:

cd "C:\Program Files\Microsoft Visual Studio 8\Common7\IDE" witexport.exe /t tfsserver /p ProjectName /n Bug /f c:\Bug.xml witexport.exe /t tfsserver /p ProjectName /n Task/f c:\Task.xml

Now open these .xml files, locate the "Assigned To" field and update it to be the following:

      <FIELD name="Assigned To" refname="System.AssignedTo" type="String" reportable="dimension">
        <HELPTEXT>The person assigned to do the work</HELPTEXT>
          <ALLOWEDVALUES expanditems="true">
              <LISTITEM value="[Project]\Project Administrators" />
              <LISTITEM value="[Project]\Contributors" />
              <LISTITEM value="Project Administrators" />
              <LISTITEM value="Contributors" />
              <LISTITEM value="domain\tfssetup" />

What this does is limit the users that are displayed in the "Assigned to" drop-down list box to be just the direct project administrators and contributors.

Import these back into TFS:

witimport.exe /t tfsserver /p ProjectName /f c:\Bug.xml witimport.exe /t tfsserver /p ProjectName /f c:\Task.xml

Next, from Team Explorer, right-click on the team project and select Team Project Settings | Group Membership.
Click on the 'New' button and create a new project group named "Unassigned".
Select the [Project]\Contributors group and add the [Project]\Unassigned group as a member.
Now, select the team foundation server from with the Team Explorer, and right-click and 'Refresh' to reload the new templates.

ADSL2+ is here!

In the time it takes to have a shower, our broadband connection has been swapped over and we now have ADSL2+!

ADSL1 (Before, Telstra DSLAM)
Upstream Downstream
SNR Margin 24.5 dB 24 dB
Line Attenuation 34.5 dB 20.0 dB
Speed 256,000 1,536,000
ADSL2+ (After, Agile DSLAM)
Upstream Downstream
SNR Margin 9.0 dB 9.0 dB
Line Attenuation 38.5 dB 21.0 dB
Speed 942,600 11,467,480

Internode have the facility to customise the ADSL2+ profile, so tweaking that may improve things slightly. I've also got a Central Splitter that I plan to install as part of our house extensions so that should help things slightly too. But you can't complain about a 10x improvement!

Data constraints in a multi-tier application

I'm wondering about what are the best practises, particularly in a .NET world for this kind of scenario, which must be pretty common. My goals are to a) have decent performance and b) have as few instances of separate (but identical) constant values as possible. Here's the scenario:

  1. You have a database with some tables, and say a table has a varchar column with a maximum length of 255 characters. All good so far! (Constant count = 1)
  2. You then create a .NET 2.0 DataSet with TableAdapters for that table, so now the DataSet also knows that the column has a MaxLength of 255. (Constant count = 2)
  3. You now create a business object which has a property which also maps to the same column (and would be persisted by passing it back through the DataSet/TableAdapter from step 2). You add checks to this property to ensure it also never gets larger than the maximum length allowed. (Constant count = 3)
  4. You create a web form (or a Windows Forms for that matter) that has a text field for the user to edit the same column. You set the maxlength attribute of that text field so the browser restricts the user to the size limit for that field. You also add a server-side validator to validate the text field and enforce that size limit (just in case their web browser ignores the maxlength attribute). (Constant count = 4)

We've managed to embed the value '255' at least 4 times in our application! While that may not bother some people, it it does annoy me. The concept of having a single constant that represents a value and allows you to easily change the value in one place should you need to is something I've adopted for a long time.

So how can we reduce this down?

Assuming that we're going to stick with a normal relational database and keep the limit for the column there, then that's one instance we can't remove.

It is true that we could use database queries to retrieve that value and use it all over our app, but I'm pretty sure the performance for that would not be ideal, and it does mean that some potential compile-time checks might be missed.

If you assume that your UI tier only talks to the business layer, and the business layer is the only thing that talks to the data layer, what is the best way to percolate through these kind of values with as few separate constants as possible? If I change the length of the column in the database, I want to change as few constants in my code as possible, so that there's less chance I miss one and cause a problem with the application.

I'd be interested in other people's thoughts, or if anyone has links to content that covers this topic.

Friday, 14 April 2006

"Hey, that's me!"

I just noticed there's a link to my blog on the Australian SQL Server User Group home page - I'm not sure how long it's been there, but then I don't always look up in the top-right corner :-)

Which reminds me, when I have some spare time I need to see if I can fix the layout problem with their Forums area in Firefox. I also put my hand up to add some RSS feeds to the site which I haven't done anything about yet.

Returning to a positive note however, I'm pleased to see that the Adelaide SQL group is doing really well at the moment. Maybe it's our jet-setting leader, or the great speakers, but we are getting regular crowds of 30+ and I'm always learning something new each time I go.

Thursday, 13 April 2006

The 'Atlas' Control Toolkit

Brad Adams mentions the release of the"The 'Atlas' Control Toolkit" - I think we will use this.

How to subscribe to Tfs alerts for new workitems only

Something to remember - BisSubscribe.exe is the command-line tool for maintaining alerts for Team Foundation Server

This tools is installed on the server, and by default ends up in the following path:

C:\Program Files\Microsoft Visual Studio 2005 Team Foundation Server\TF Setup

Supposedly, you can list all the events that can have alerts attached to them by using the web service on the TFS box - eg. http://localhost:8080/Services/v1.0/registration.asmx/GetRegistrationEntries but this fails with an exception for me.

Wednesday, 12 April 2006

"Atlas" April CTP Release

We've taken the decision to run Visual Studio 2005 Professional for now (until we figure out the costs of going to Team Edition)

I thought this also might be the ideal time to do a complete reload of my workstation. A chance to re-install everything from scratch and lose all the accumulated rubbish that ends up on your PC after a year or two of use.

This isn't something I do often, as it take about a day and a half to reinstall the OS + all the various applications that I regularly use (approximately 50 on my list)

But one day on, and my list is already out of date! Time to uninstall the March CTP of Atlas and try out the April one. Roger's already making use of Atlas in our new Online Assessment Tool that we're working on, so this is relevant to us.

Monday, 10 April 2006

Friday, 7 April 2006

Visual Studio Team Foundation Server MSSCCI Provider

Enables integrated use of Team Foundation Version Control with products that don't support Team Explorer integration.

Wednesday, 5 April 2006


I came across this free .NET graphing/charting component. It work with Windows Forms as well as ASP.NET.

Thursday, 30 March 2006

Wanted: Network profile changer for PocketPC

I have an HP iPAQ 4150 PocketPC device. Not the latest and greatest, but it works pretty well.

Now that I have a wireless network at home, I've struck an annoying problem: The Wireless network at work requires authentication via a VPN and can only get to the Internet via a proxy server. My network at home however doesn't require the VPN or proxy configuration.

What I need is a nice little applet that will run on my iPAQ and that will swap the network settings over depending on if I'm at work or at home. It doesn't need to do that automatically - pressing on a button manually is ok. It would just save me messing around with all the network settings every time I want to get it working again.

I had a quick Google but couldn't find anything that seemed to fit the bill.

ObjectDataSource and sorting

I struck this error today - "Automatic sorting is only supported with DataView, DataTable, and DataSet". It was caused by binding a custom collection through a DataSourceObject control.

Scott Guthrie suggests in a comment to this post to either implement a custom comparer, or make use of the SortParameterName property of the ObjectDataSource control.

I ended up doing the latter, as I need to be able to sort the collection on more than one property. My middle-tier expects this as an extra parameter, and then uses a DataView to sort the DataTable before it creates the custom collection.

Friday, 24 March 2006

Cumulative Hotfix for SQL Server 2000 Service Pack 4 - Build 2187 for x86 and x64 Based Systems

This package contains all hotfixes that are available for SQL Server 2000 Service Pack 4 prior to build 2187.

This build contains hotfixes that were available for SQL Server 2000 Service Pack 3 build 1031 but were not included in SQL Server 2000 Service Pack 4.

Thursday, 23 March 2006

Microsoft Visual Studio 2005 - Update to Support Web Application Projects

This update enables migration wizard support and an improved designer experience when using Web Application Projects.

You can get the Web Application Projects add-in from here

Sunday, 19 March 2006

Code analysis and flowcharting utilities

Might have to give these a try out on some of my code. If the diagrams get too complicated, then it's probably a good sign that the code could use a re-write!

Friday, 17 March 2006

SQL Server 2005 SP1 March CTP

SQL Server 2005 has only been out for a few months and they're already working on Service Pack 1!

The list of fixes will eventually be posted to KB article 913090.

Wednesday, 15 March 2006

How delete all the data in all the tables in your database

Adi has a nice way of removing all the data. The only change I made was to use "DELETE FROM" instead of "TRUNCATE TABLE" so that it works with foreign keys.

Tuesday, 14 March 2006

My 711CE is dead, long live my 7404GL

It is a sad day - in the last few days, my Billion 711CE had become very unreliable - locking up regularly after a few hours use. It has been so reliable, and I had high hopes that it would keep powering on for another year or so, even after our exchange got upgraded to ADSL2+.

But it wasn't to be. And seeing as we use VoIP for our phone calls, it is kind of important to have a reliable and stable Internet connection. So I've stuck with Billion, and gone for a BiPAC 7402GL purchased from Mark at MATS Systems.

I didn't need the VGL model, as I already have a Sipura 3000. The features are certainly more advanced than the 711CE could offer. The 11g wireless is a nice bonus, and the extra LAN ports means I can retire my mini-switch for now too (a small power consumption saving there).

Friday, 10 March 2006

Threat Analysis & Modeling v2.0

As seen at the recent Adelaide Security seminar, here is the latest threat modelling tool from Microsoft.

Wednesday, 8 March 2006

Code profiling, memory profiling - ANTS Profiler

I'd like to see a comparison of the ANTS profiler versus the inbuilt performance analysis tool in VSTS

For that matter, it would also be interesting to compare it with Rational Quantify too. I've got that, but have not found it the most intuitive tool to use, and am also wondering about IBM/Rational's commitment to .NET.

Monday, 6 March 2006 Cookbook

When UniSA implements SIP, then I'll be able to ring work numbers for free!

I made my first real SIP Broker call tonight - now that Chris has his Sipura 3000 up and running!

Fast transactions with System.Transactions and Microsoft SQL Server 2000

ClearType in Internet Explorer 7

After reading this article, I've turned on ClearType to see if I think it makes a difference.

I've got LCD displays at home so it looks quite nice on those. Unfortuately, the Philips 109S4/75 monitors I have at work don't appear to use Trinitron, but I'll still give it a go here too.

Wednesday, 1 March 2006

Bug: Refreshing schema of ObjectDataSource causes error

I think I've found another bug in Visual Studio.NET :-(

I've got some DataObject classes that return arrays of objects. These used to return collections (using the System.Collections.ObjectModel.Collection generic class). I updated them to return simple arrays as I thought that would be more efficient.

Turns out that while ASP.NET seems to work fine with this, the design experience in Visual Studio isn't so good. Clicking on the 'Refresh Schema' task on the ObjectDataSource control that references the data object method, causes a "The schema of type 'Class1[]' could not be retrieved. Operation is not valid due to the current state of the object" error to be displayed.

Tuesday, 28 February 2006

Microsoft Security Interchange notes

Last night Gary, Chris and I attended the Adelaide edition of the Microsoft Security Interchange evenings that they are running around the country.

It was a relaxed evening, but there were some good speakers. Most interesting and entertaining would have to be Steve Riley. I've heard Steve and Jesper talk at TechEd previously, and he is a very compelling presenter. I wish some of the ISTS guys had been there to hear him talk about how "account lockout" is just a great way to mount DoS attacks on user accounts. It's also worth repeating the security tradeoff triangle diagram:

Rocky Heckmen also did an interesting presentation where he showed a new tool that will be released soon from Microsoft that helps with Threat modeling.

Dave Glover finished up with some demos of techniques to help improve code security. Sadly, encrypting web.config didn't work for him on the night, but he did also mention the Anti-Cross Site Scripting Library that I blogged about last week. Turns out this includes security-conscious versions of the Server.HTMLEncode and Server.UrlEncode functions

Sunday, 26 February 2006

Thursday, 23 February 2006

This week's brushes with fame

So far this week, I've had contact with two 'famous':

First of all I've had a few emails going back and foward to Scott Guthrie, a pretty high-up guy at Microsoft who looks after the teams that produce ASP.NET, Visual Studio web bits and IIS). I've got a problem with the Web Application project that is currently in beta. I think it's a bug, so hopefully they can fix it for the next update.

The second person was a reply from Mark Russinovich, one of the guys behind Sysinternals. I reported an issue I'd seen with the BlueScreen Screen Saver when running remote desktop (it displays a funny error message).

Wednesday, 22 February 2006


dmitryr's blog : ASP.NET RSS Toolkit

My first generic method

Since starting to use .NET 2.0, I've made quite a lot of use of the Generic Collection classes.

Today however was the first time I've created my own generic method that adapts to the required type for each instance.

The use of the method is to replace the following kind of code:

        Dim rowTest As dsTests.TESTSRow
        rowTest = dtTests(0)
        If rowTest.TEST_PUBLISHED <> test.Published Then
            OnDataItemChanged(dtTests.TEST_PUBLISHEDColumn.ColumnName, rowTest.TEST_PUBLISHED, test.Published)
            rowTest.TEST_PUBLISHED = test.Published
        End If

Basically, I'm checking if the value has changed, and if it has then I update the DataRow property, and eventually I call a DataAdapter to send the updates back to the database. By doing the compare, I'm only sending real changes back to the database.

My first step was to create a helper method that took an object as a parameter like this:

    Public Shared Sub UpdateDataRowItem1(ByVal row As Data.DataRow, ByVal column As Data.DataColumn, ByVal newValue As Object)
        Dim oldValue As Object = row(column.ColumnName)
        If oldValue <> newValue Then
            row(column.ColumnName) = newValue
            OnDataItemChanged(column.ColumnName, oldValue, newValue)
        End If
    End Sub

But as the squiggly lines appeared in Visual Studio, I realised that this wasn't going to work if I stuck with the general Object data type - you can't use <> with Object types! The alternatives were to create separate versions of the method for the different types, or I realised I could make use of generics to do the same thing but in a much easier to maintain way.

My first question was "Can you actually have generic methods?", as I didn't really want a whole class to do this. Thanksfully, the answer is Yes. So I updated the method to look like this:

    Public Shared Sub UpdateDataRowItem2(Of t)(ByVal row As Data.DataRow, ByVal column As Data.DataColumn, ByVal newValue As t)
        Dim oldValue As t = CType(row(column.ColumnName), t)
        If oldValue <> newValue Then
            row(column.ColumnName) = newValue
            OnDataItemChanged(column.ColumnName, oldValue, newValue)
        End If
    End Sub

Getting closer, but it was still complaining - "Operator '<>' is not defined for types 't' and 't'". Going back to check the documention, I noticed one of the examples used a 'constraining type' on the type parameter. That is just what I needed too, so the final version is as follows:

    Public Shared Sub UpdateDataRowItem(Of t As IComparable)(ByVal row As Data.DataRow, ByVal column As Data.DataColumn, ByVal newValue As t)
        Dim oldValue As t = CType(row(column.ColumnName), t)
        If oldValue.CompareTo(newValue) <> 0 Then
            row(column.ColumnName) = newValue
            OnDataItemChanged(column.ColumnName, oldValue, newValue)
        End If
    End Sub

Unit Testing Events with Anonymous Delegates in .NET 2.0

How do you unit test your event code? You use Anonymous Delegates

Here's a sample unit test that I've created that makes use of this technique:

        public void UpdateTestTimesTest()
            object expected = UniSA.UniSAnet.SmartMark.DataAccess.DataItemChangedEventArgs.ChangeType.Update;
            object actual = null;
            UniSA.UniSAnet.SmartMark.DataAccess.TestComponent.DataItemChanged += delegate(object sender, UniSA.UniSAnet.SmartMark.DataAccess.DataItemChangedEventArgs e)
                actual = e.Change;
            Test test = UniSA.UniSAnet.SmartMark.DataAccess.TestComponent.GetTest(UnitTestingTestId);
            test.MinutesAllowed += 1;
            Assert.AreEqual(expected, actual);

Wednesday, 15 February 2006

Default content in ContentPlaceHolder is not replaced when it contains <%= %> tags

I think I've found a bug in ASP.NET Master Pages - if you try to include any <%= %> tags in a ContentPlaceHolder control on a Master Page, then it doesn't get overidden by the content in the Content control.

Using CSS when JavaScript is disabled

I've often worried about pages that use CSS to hide content, then allow JavaScript to dynamically show it again (eg. when you click on something), that if JavaScript was disabled, then there's no way to show the content.

Project Seven shows an example of how to use CSS and make sure content is viewable with or without JavaScript enabled.

Click on the example to see how it works.

Wednesday, 8 February 2006

TFS Data Warehouse not updating

I noticed today that the reports section of our intallation of TFS were not updating - they were still only showing 24th January. Here's the workaround.

Friday, 3 February 2006

Extending Enums

A couple of articles on adding attributes to Enums.

Combine this with a custom TypeConverter and you've got some nice code to work with.

"the handle is invalid" error with VSTS and TFS

We've struck this error trying to check-in a file in Visual Studio Team System. You get a very helpful dialog that says "The handle is invalid".

Turns out this is a bug that has been fixed post-Beta3, and bites you when two people have checked out an item. The workaround is to use the Get Latest Version menu-item, merge changes then you should be ok.

See this post in the MSDN Forums for more details.

Uploading Files in ASP.NET 2.0

An Overview of using the FileUpload server control in ASP.NET 2.0.

Wednesday, 1 February 2006

Jeff Beehler to Visit Australia March

Jeff is involved in the Team Foundation Server product from Microsoft. His Blog is one I keep an eye on for the latest updates in TFS.

I've asked Chuck if there's any way to get him to visit Adelaide on his Australian visit.

Tuesday, 24 January 2006

Usability Week 2006 Conference

Nielsen Norman Group are running another Usability Conference in Sydney. Courtney went to one of these events in previous years and got a lot out of it.

"Cheap" registration is available up until June 16th.

Wednesday, 18 January 2006

Retaining wall progress

David bring another load of concrete for GeoffThis morning Geoff and Graham and two cement Trucks arrived to put the steel upgrights into the ground for our retaining wall.

Sadly, due to over-enthusiastic watering from a neighbour's garden last night, 4 of the holes were flooded and unusable, despite a last-minute bucket-brigade effort this morning.

I helped out with taking wheelbarrow loads of concrete to fill all the holes (I only lost one load!)

So, we will have to get Rod with his excavator back to drill out the 4 wet holes before we can finish the wall. Hmm, I wonder if this will all be done by Winter after all?

 Posted by Picasa