Nick's .NET Travels

Continually looking for the yellow brick road so I can catch me a wizard....

Podcasts and User Interface Design

Over the weekend I was asked a couple of times what podcasts I listen too and how do I find the time?  Well the short answer is that I only find 30min (approx) on the way to and from work. I catch the train which usually entails a 10 minute walk to the trains station, 5 mins of waiting for the train, 10 mins on the train and then a further 5 mins walk to the office.  As such I usually end up listening to about a podcast (occasionally 2) a day.  I typically choose from the following list:

<Self Promotion>The Microsoft Developer Show - A (mostly) weekly show that features developers around the world working with Microsoft technologies</Self Promotion>
Arcast - A great architecture show hosted by Ron Jacobs out of Microsoft (speaking of which he will be visiting NZ next week!)
Dr Neil's Notes - Neil Roodyn's weekly synopsis of what is happening around the traps
UberTablet - Mr Tablet PC himself, Hugo occasionally finds the time to talk it up with people doing things in the Tablet/UMPC space
OnTheRun - All the technology you can get your hands on and more
dotNetRocks - One of the longest running shows and IMHO goes for too long and tends to be drawn out.  Still a great listen but you need a good hour of time to kill
HanselMinutes - I've only just started listening to this show and it's been great. A wide cross section of topics!
SQLDownUnder - Greg Low talks about everything data and not just with people down under

The other point of interest that came out of SQL Code Camp followed Adam's insightful presentation on Reporting Services best practices (which would be more appropriately labelled "Adam's rules to better reporting"). On the way back to the city I asked Adam who he turned to for information on user interface design.  In typical Adam fashion his answer was himself.  One of the concepts behind the product we have built at Intilecta is that there are two distinct parts, the core delivery platform (otherwise known as the content delivery platform or the CDP for short) and the content itself.  Unlike most ISVs who build a product then worry about how it looks, a large proportion of our development resources (and testing) have gone into building intuitive, effective and minimal interfaces.  To this end we have a number of reference books that we consult for opinions.  We also try to read a number of design oriented blogs and other design critiques.  A couple of the names that are worth a read:

If you know of anyone else who has a great eye for user interface design, please feel free to add a comment!

P.S. did you know that there is a new member of the DPE team in Australia, Shane Morris, who is a User eXperience Bloke!

While C# has the &quot;because&quot; operator, VB.NET has the &quot;why&quot; query operator

Although VB.NET has in the past missed out on some fairly crucial language features such as anonymous methods and iterators (both absent from VB2005 which shipped with .NET FX 2.0) it seems that it is going to edge C# out in the race for the most obscure operators.  Mitch posted about the C# implementation of the "because" or "justification" operator.  The VB.net equivalent will looks something like:

1 + 1 = 2 because 2 - 1 = 1

1 + 1 = 3 because true

1 + 1 = 3 justbecause

Although the implementation is a little more wordy (literally) they extended this concept by adding the "why" operator.  For example

why 1 + 1 = 2

The real question would be what does the why operator return and where could you use it.  Well in the simplest terms the why operator allows the framework to expose any previously defined truths.  For example in Mitch's case where he defined the truth 1 + 1 = 3, you could write the query why 3 + 3 = 9 which would return a proof which includes the truths (1 + 1 = 3, 1 x 3 = 3) as well as an execution plan in the form of a proof tree indicating the order that these truths are applied.

You would think this would be something that C# could easily add into their syntax, allowing you to write:

¿ (1 + 1 == 2)

But unfortunately I have it on good authority that C# will not get this feature as they deem it to be too productive and is a security hole as it allows the developer to query the logic of the .NET Framework developers at Microsoft.

Why did Microsoft break Outlook 2007?

Ok I have to admit I'm a big fan of everything Office 2007 with one MAJOR exception.  The synchronisation built into Outlook 2007 sux and is considerably worse than Outlook 2003 - don't ask me how it can be worse but it is.  I used to synchronise using RPC over HTTP so that I can sync regardless of what network I'm on.  For some reason this seems to hang.  To get around this I now connect to the VPN and sync using the LAN.  This was acceptable until today.  I've been sitting at SQL Code Camp (NZ) on the CafeNET wireless network (plug for the kind sponsors of this event) and despite being connect to the VPN I still can't sync my mail.  I can however access the OWA web client at reasonable speed - go figure.  Microsoft you MUST learn how to build a product that can synchronise, afterall it's just not that hard.

Update: After a thinking about this post again last night I realised that I should probably include some footage of exactly what's going on and why I think that the information provided to the end user in Outlook is pathetic and occasionally just plain wrong! Here is a rough sequence of images (thanks to SnagIt) that shows just how bad Outlook is.  Remember I am connected using a VPN connection and I can not only access my email using OWA, I can also access the fileshare on the same server that Exchange is running on (we are using Small Business Server).

Just Connected: This seems to be quite sensible, Outlook detects that I've connected to a new network so it goes exploring to see if it can communicate with the exchange server

Sending Completed: Progress indicator states that "2 of 3 Tasks have completed" - ummm, I only see 2 tasks in the list and only 1 of them states that it is complete.

Not Really Completed: Hang on, the progress indicator states that Sending was completed, yet I still have mail waiting to be sent (I actually pressed send yesterday morning and have been waiting over 24 hours for this to go - I'm glad this wasn't an urgent email).

Now there's an Error: Oh, so now Outlook has realised that yes there were indeed only 2 tasks and that neither could be complete because the server is unavailable (remember at this stage I can still access everything on this server)

Still no connection: Now Outlook has completely given up and stated that it is just disconnected (read: I can't access the server, not my problem, fix your connection and I'll try again but in the meantime it's not my problem).  Again remember I can access the server (and it's not even that slow)!!!

Update 2: Turns out that half my problems were related to my Small Business Server (which is of course running my exchange instance).  This server has been extremely reliable but decided over the weekend to "require a reboot".  Of course there was nothing in the event logs to indicate this and AFAIK there was no way of my working out what was going wrong.  I was online talking with SBS guru Wayne Small when I decided to logon using remote desktop, check for (and install) any updates and then reboot the server.  Not sure whether it was an update or the reboot but the server seems to be ok again and I once again have email (on either RPC over HTTP or VPN connection).  The moral of this story is still that the error information is not good enough.

One trick I did learn from Wayne, that perhaps was in the Outlook 101 lesson I must have missed, was that if you hold down Ctrl and click on the Outlook icon in the taskbar there are a couple of additional options in the pop-up menu.  The one that helped me out a little was the "Connection Status..." item.  Great tip if you are having connectivity/sync issues with Outlook.  Thanks Wayne!

Setting up SQL Server CE replication on Vista with IIS 7.0

Over the last couple of days I have rebuilt my laptop with the RTM build of Vista.  As expected there have been a few hurdles, the biggest of which was getting replication to work.  With SQL Server Management Studio I could easily create the publication but setting it up as a web virtual directory (so that it can be subscribed to by SQL Server CE) was another matter.  After installing Vista I went into the Add/Remove programs and selected the IIS windows component.  Unfortunately this doesn't include the II6 compatibility API - which most applications that were designed for II6 and earlier use.  To get the virtual directory setup you need to install the compatibility API by checking the option selected in the following image (you also need to be running SSMS as administrator to communicate using these APIs)

More annoyances with Vista

A while back I blogged about the difficulty associated with installing a certificate from an HTTPS site to add it as a trusted provider.  Yesterday after installing Vista RTM I remembered the other pain point I was having.  In previous versions of windows when you go to login you can elect to connect via a dialup connection (prior to logging in).  This is useful if the network you are on is not your LAN and you need to VPN into a domain in order to authenticate.  Unfortunately this option seems to have disappeared in Vista (maybe it’s there and I just can’t find it). 

 

There is a work around as Vista now supports switching domain users (previously you could only switch users if the computer wasn’t connected to a domain).  So, you log in using a local computer account, connect to the VPN, switch user and log in as with the domain account.  Luckily you only need to do this the first time for each domain user as the local computer will cache the login credentials (effectively allowing you to login while disconnected).  Once you have logged in with the domain account you can of course connect the vpn to get access to domain information etc. 

You know you are a Beta junkie when.....

After numerous woes with my upgraded Vista machine (IBM T43 laptop which I upgraded from RC2 to RTM) I decided last night to commit and rebuild my machine. The good news is that installation went without a hitch and that it found drivers for all the hardware (of course this doesn’t include any of the IBM software to drive the hardware buttons etc but then again I don’t have the overhead of poorly coded, often bloated vendor software). The bad news is that despite my best intentions to only install rtm'd products I once again found myself installing non-supported or beta software. The list of applications/versions I'm waiting on are

 

VS2005 SP1 (although VS2005 will run there are issues with UAC - which I am determined to leave on this time)

Live Mail Desktop (I need this as it seems to be the only RSS product that uses the IE7 common feeds store, doesn’t break Outlook2007 and has an unread items view – don’t ask me why IE7 doesn’t have this)

Virtual PC 2007 (for doing presentations and installing beta software ;-)

OneCare (maybe - atm i have AVG installed and that works a treat. Why if i'm only using the computer for personal stuff would i pay for a OneCare subscription?)

VS2005 extensions for WPF, WF (to do work with .NET Framework v3)

SQL Server 2005 CE

Windows Mobile Device Center (so I can’t connect and establish partnerships from my WM device to Vista – replaces ActiveSync)

 

I must admit although this looks bad you have to remember that Vista is technically not shipping until early next year to retail customers.  Whilst I’m sure that there will still be some teething problems I would suggest that most of these products will have shipped by then.  The Test pass for a new operating system is much longer than for any of these standalone applications which means that their release cycle can be significantly shorter.  This also means that Vista could be RTM’d without being delayed for these products to RTM.

 

One last comment on this matter.  The reason that I try to avoid installing Beta software on my production machine is that MOST software vendors (including Microsoft) can’t write a good installer to save their lives.  A good installer will not only correctly install the product it will uninstall the product and any traces that the product exists.  If there are local data files that the application creates when it is run, there should be prompt in the uninstall process that allows the user to decide if they want to include those files in the uninstall process.  There should be no registry traces of the application and the uninstall process should replace any files that were overwritten as part of the install process.  Unfortunately for most companies the installer is the last thing to get built and is seldom tested with the same rigour as the product itself.

Why Sale/Buy when you can Lend/Borrow?

I was reading Peter’s comments about New Zealand company TradeMe this morning and I must admit I have had mixed experiences. In one case the seller didn't get back to me in a timely manner so I cancelled the trade, he then proceeded to black mark me. The other couple of times I have used the site it has been very efficient for buying items.

 

This also reminded me that a local group have been using Ruby on Rails to build a site where you can borrow or lend items, called LetUseIt. It works on a similar principle to TradeMe as it generates revenue as a percentage of the lending fee but also includes tracking assets for insurance purposes. Having only recently gone live it will be interesting to see this site grow. 

Honey I shrunk the framework (again)

Just when you thought there were enough versions of .NET Framework (v1, v1.1, v2, v3, v3.5 + .NET CF v1, v2) the clever guys at Microsoft have announced another version entitled the .NET Micro Framework.  As Daniel Moth points out they have just released a product sheet.  They have also just released a webcast which you can view here and for a limited number of participant there is a beta program available via http://connect.microsoft.com (listen to the webcast for more information on how to get involved).  As I mentioned in my previous post the Vista SideShow is powered by the .NET Micro Framework so this is a great opportunity to jump the gun and start building really cool gadgets.

Gadgets, Gadgets, get your Gadgets here....

So you have probably heard about Live gadgets and if you have been playing with Vista you will have see the SideBar Gadgets but what you may not have seen are SideShow gadgets.  What's a SideShow, well it is the small display on the outside (typically) of a laptop that could show things like the time or information about the song that is currently playing.  It is very similar to the reduced display that some mobile phones have on the outside.  Well the great news is that it is going to be possible to build gadgets for the SideShow.  Without steeling his thunder I suggest you check out Daniel Moth's blog and the the SideShow blog for more information.  If you are interested, you should also keep tabs on the new .NET Micro Framework.

Microsoft Sync Services

On Wednesday morning Steve Lasker delivered his second public webcast (the first is available for viewing here) on the up and coming Microsoft Sync Services. For anyone who has worked with sql mobile, now sql server ce again, one of the biggest issues is how to replicate data  between a central server. Whilst there are all sorts of ways that a custom solution can be written (for example datasets across webservices or an Xml blob via a raw http request) there are current two mechanisma that are built into the platform to support syncing with sql server, RDA and Merge replication. RDA is essentially a client configurable set of queries that can be used to pull down a specific set, or subset, of the server data. Merge replication is a server configurable publication to which the client can subscribe. Both of these mechanisms work via an IIS virtual directory making it possible to sync across the web. This also leads itself quite nicely to securing the data as SSL can simply be applied to the webserver.

 

There are significant limitations to both RDA and Merge. Which is where  MSS comes into play.  Instead of being just a client or server technology, MSS appears to have both client and server code that is written by the application developer to control how the sync process behaves.  This includes whether the sync will be done directly (which would be the preference on a LAN) or indirectly (ie via a webservice proxy).  It also includes hooks so that the application can handle conflicts and get access to updates before they are applied.  This looks an exciting product and I can’t wait to see the CTPs.

 

Also, it is worth pointing out that a fellow MVP, Bill Vaughn, has released his first eBook on SQL Server CE.  Check it out at http://www.hitchhikerguides.net/EBooks/Titles/default.aspx

OneCare &quot;appears&quot; to fail as first line of defence

This morning I was in the middle of listening to a webcast when OneCare pops up and declares that it is going to apply an update.  I'm getting used to the annoying bubbles that keep popping up to indicate the OneCare is yet again update (probably my fault for not disabling them) but this time the update notification took the form of a dialog that needed to be dismissed and looked like the following:

Now I'm no security guru, but the fact that "OneCare will not be available" while it is doing the update leads me to believe that my computer is exposed to viruses, hackers etc.  In actual fact I suspect hope that this is just the wording of the dialog and that in fact OneCare is still functioning as my virus protection and firewall while the update is being applied.  Perhaps this wording needs to be improved to encourage users that their computer is still in fact safe.

My privacy has just walked out the door....

Earlier this morning I was enquiring about the Scitech .NET Memory Profiler so I sent them an email to their support email address.  As their website indicates they use FogBugz and have clearly put in place an automated system that takes your support request and adds it into FogBugz VERBATIM.  The following screenshot indicates that not only have they included all the header information (including my email address, which I have removed from the image) it also includes any attachments, which in this case is my vcf (which has all my information such as mobile phone, email, im address etc).  This information is available to anyone without a login!!!! Where's my privacy.  As you can see from my follow up email I was a little less than happy.

BlogMailr

Following Mitch’s lead I thought that I would try out BlogMailr.  Like a lot of people I know, outside of Visual Studio, I spend a large proportion of my time in Outlook.  Prior to using BlogMailr I was using the beta of Windows Live Writer which was quite nice, but yet another application I need to ALT-Tab between.  Now I'm able to write and submit blog posts ust by sending an email to the BlogMailr server.  It takes care of posting the item to my blog that I've configured via their website.  If you have multiple blogs, you get a different email address to send the items to (great idea for multi-posting!).

A couple of great points about BlogMailr is that not only does their website use Community Server, it is also free for personal use!!! 

WPF/E is not a Me Too technology

According to Joe Stegman WPF/E is not a "me too" technology that follows in the path of Flash and other rich media technologies.  While there are many aspects of this proposed technology that would appear to indicate it is following this road, the biggest distinction is that it is designed with Microsoft developers in mind.  This means (hopefully) a reduction in the use of Javascript and an increase in the amount of managed code we have to write for a rich web experience. I must admit at this point I can't wait to see the CTPs as I think that the "proof is in the pudding".