Technology Bits

Updating the status of technology in my life, in no particular order.

Browser Wars.  I’ve more-or-less fully switched to Firefox 3.5 as my default browser.  For web development it’s hard to beat the Firebug and HTML Validator plugins.  And for web browsing in peace, the NoScript plugin is pretty awesome.

I tried Chrome again recently for general web browsing, and, while it is noticeably faster than Firefox, I found that I just couldn’t live without NoScript — there are soooo many scripts out there that really need to be blocked.  But for sites that I trust, I’d have no trouble using Chrome.

I still occasionally use Internet Explorer 8, mainly for bank sites that are horribly coded and don’t work with anything else.

Media Center.  I now have an older Windows XP box hooked up to the television in the living room to serve as an Internet media center, for watching YouTube, Hulu and Netflix on the TV.  I use Miro for watching Revision3 and Mevio video podcasts, and I also use XBMC to stream music and picture collections to the living room, which I’ve shared on the network with TVersity.

I tried Ubuntu on the media center, but it was just too much of a hassle.  Maybe it would work better with a newer PC.  Linux on the desktop isn’t quite ready for non-tinkerers yet.

My favorite Internet shows, by the way, are Cranky Geeks, Tekzilla and Film RiotSystm was also a favorite but they’ve discontinued it.

Zune.  I’ve enjoyed my Zune 8 a lot more than I expected I would.  I use it mainly for listening to podcasts in the car on the way to and from work, and occasionally for listening to music at work.  The Zune desktop software could be better, but it covers the basics.  I don’t use the Zune marketplace — I get my music from Amazon right now.

I’m really looking forward to the Zune HD… if it works like they say, it could entirely replace the aforementioned Windows XP media box.  A portable web browser in the palm of your hand — and it’s not an evil Apple product, or chained to an evil cell phone company!

How To Fix IE8 Links Not Working

If you’re having trouble with Internet Explorer 8 not opening links in Vista, try running IE once as an Administrator.

I have my wife setup to run as a Standard User on her Vista SP1 laptop.  After installing IE8, first from a downloaded installer file and then later from Windows Update, she found that there were certain links that simply wouldn’t work.  That is, she’d click a link and nothing would happen, as if it were ignoring her.  There were no messages or indicators of any kind.

It turned out that the links in question opened up another browser window or popup of some kind.  If you held down CTRL while clicking the links, it would open a new tab but still never loaded the page.  I tried to disable the popup blocking and fully trusting the sites in question but neither of those things fixed it, nor any other option I could find.  Eventually I tried logging into the Administrator account to run IE8 from there, and everything suddenly worked as expected.

Now my wife reports that she is able to click links as before from her Standard User account.  Presumably some kind of one-time initialization needed to occur under a full Administrator account.

I logged in as an Administrator, but it may also work if you simply use the Run As Administrator menu.  Give it a try if you find that links don’t work for no apparent reason.

Upgraded to AMD and Vista x64

I recently upgraded my home computer to a 2.6GHz AMD Athlon X2 5050e with 4GB of memory.  Parts for this upgrade, including a whole new case, motherboard and hard drive, cost about $350.

In the past, I’ve been an Intel guy, so this is my first big foray into the world of AMD.  I made the switch because I built a system for my mother-in-law last year from an AMD processor, which was slightly cheaper, and I was pretty impressed with how it turned out.  Mrs. Krehbiel also got a laptop last year with an AMD processor and it’s been working well, too.  So I figured, why not?

As far as I can tell, there’s absolutely no reason not to get an AMD anymore.  The days when software might not run quite right on AMD processors are long gone.  It seems like the price difference between AMD and Intel is much smaller these days, too.  So basically it’s a toss-up.

I also decided to install the 64-bit version of Vista.  I keep hearing that it runs much better in 64-bit mode.  I can’t say that I’ve seen a significant improvement, but it’s a little better.

Unfortunately, you’ll find that there is not very much native 64-bit software out there besides the operating system itself.  Thankfully 32-bit software usually runs fine on Vista 64-bit, but it installs into a weird “Program Files (x86)” directory instead of the normal Program Files.  The only software I’ve found so far that doesn’t run on 64-bit Vista is Peer Guardian and Taskbar Shuffle.  (Taskix has a 64-bit version, though, and it works fine.)

As of this writing, there is still no Vista driver for my Microtek ScanMaker 4900, 32-bit or 64-bit.  I have to keep it hooked up to an older computer.

Zune Obtained

I bought a Zune last week.  Yeah, a Zune.  Big woop.  Wanna fight about it?

It wasn’t on my radar to get one, but I was buying some new computer hardware from NewEgg, and as I was checking out, it gave me that evil message, “if you buy another $100 worth of stuff, you’ll qualify for 6 months interest-free!”  Of course then I had no choice. 🙂

This is the first MP3 player I’ve seen in a long time.  I can report that portable MP3 players have come a long way since the Diamond Rio PMP300 I bought back in 1998.  Back then it came with 32 MB of memory.  That was enough to hold – maybe – one album of music at 128Kbps.

My new Zune is tiny in comparison to that Rio and has 8 GB of memory.  That’s about 256 times more storage space, which will hold probably 200 CDs or about one third of my entire MP3 library that’s been growing steadily since 1998.  Pretty amazing.

Okay so you’re probably wondering why I bought the much-maligned Zune instead of an iPod.

Mainly it’s because I’ve never liked the Apple business model of packaging unremarkable hardware and selling it for a premium.  (Don’t tell John Hodgman, but Macs have basically the same hardware as PCs, if you hadn’t noticed.)  They are like the Bose speakers of the computer world.

Additionally, I feel compelled to punish Apple for running the iTunes Store for so long with DRM-protected, crappy-quality 128Kbps songs*.  Besides the moral objection anyone should have to DRM-protected media and inferior quality audio, I tried getting some DRM-protected music from Napster for a while and it was a pain in the butt.  Now I buy MP3s exclusively from Amazon… no DRM, 256Kbps quality, and it’s the same price (or cheaper).

I’ve also heard anecdotally that Zunes sound better than iPods, which is a pretty major consideration for this audiophile.  Never having laid a hand or ear on an iPod, I can’t confirm or deny the reports, but I do know that 256Kbps MP3s sound pretty good coming from this dinky little Zune with the default ear buds.  (And yes, I can hear the difference between 128Kbps and 256Kbps.)

Also, the Zune was cheaper than the 8 GB iPod Nano at NewEgg.  And there was a $10 off special on the blue one.

Anyway, I’m perfectly happy with the Zune.  The biggest negative I can find in the Zune is that the lowest volume setting is just a smidge too loud.  I wish it had one lower setting, like a 0.5.  Most of the time I just want some faint background music to help me concentrate, but I still want to be able to hear people talking around me, and especially to me.  Also, the battery doesn’t last through an entire work day for me… it died somewhere around the 7 hour mark.  Not really a big deal for me, though, since I’m almost always near a USB port.

The Zune software is pretty cool, too.  Simple and clean. (UPDATE: The software looks nice but the functionality is mediocre at best; see comments.)  I’m having great fun with podcast subscriptions.  They are perfect for the commute to and from work (and usually intolerable at any other time).

At some point I want to look into writing software for the Zune, which I believe is done with XNA Game Studio 3.0.  I’ve been wanting to try some embedded programming for a while now.

* To be fair, iTunes announced in January 2009 that they will be moving exclusively to 256Kbps DRM-free songs.  But you can bet they wouldn’t have if Amazon hadn’t forced their hand.

How to Rename a Windows Service

I came across a situation where I wanted to rename a Windows service that had already been installed.  (In this case I wasn’t able to rebuild the application to alter the service installation properties, which would of course be the ideal solution.)  Google was spectacularly unhelpful, so this is how you do it:

Open RegEdit.

Navigate to HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServices.

Find the key for the service you want to change and simply rename it.

RegEdit screenshot

A reboot was necessary for the change to take effect in the Services snap-in.

You may also encounter a sub-key called DisplayName that you can change.  This is not the same as the key above.  When using “net start” and “net stop,” for example, you need to refer to the key name above.

DisplayName screenshot

I did this on Windows XP and Windows Server 2003; presumably it will also work in Vista, etc.

STANDARD REGEDIT DISCLAIMER:  Do not attempt this unless you know what you’re doing.  The consequences of a mistake could be disastrous.

Fed up with SyncToy

I’ve been trying to use Microsoft’s SyncToy for my directory synchronization tasks, and I’m just about fed up with it.  For reasons I can’t fathom, it routinely “forgets” what to synchronize.  I frequently synchronize to and from a USB stick, and I find that SyncToy usually wants to copy far more files than have actually been changed.  Like I’ll make a couple of changes to some files on the stick, and then for some reason SyncToy thinks it needs to re-copy all kinds of files from both the stick and the computer.  So I end up having to copy files manually from one side to another.  It’s a bit aggravating.

I guess I’m going back to TreeComp, a freeware program I first used in about 2003.  It looks godawful but still works better and faster than anything I’ve seen.  We’ll see how it goes on Vista.

Azure and C# 4.0 at PDC

Most of the buzz from Microsoft’s PDC is about Azure and C# 4.0.  I don’t usually pay too much attention to bleeding edge Microsoft technology until it might actually be used in real-life situations, but I thought I’d break from tradition and peek at these two shiny new things.

Windows Azure Services

There isn’t a lot of concrete information available on Azure yet, so there isn’t much to say about it.  Conceptually, it’s a specialized web hosting service from Microsoft for your ASP.NET web apps.  It’s specialized because it’s designed for the large numbers of processors and mass storage requirements needed for large-scale enterprise applications (large-scale as in, for example, Amazon or Facebook or Google).

From a programmer perspective, I gather that the main difference from a regular web app is that the details of the OS and hardware your application is running on is abstracted away from you.  For example, instead of your web app reading and writing files with the System.IO namespace, you’ll use SQL Services to read and write “blobs.”

I personally can’t think of any applications I might use Azure for.  (Do we really need another Amazon?)  It would have to be something mandated by a pointy-haired boss-type.

As for the “cloud computing” part of it; well, I’ve said before that I don’t much care for cloud computing.  Besides all the privacy and data loss concerns, the bottom line is that “the cloud” is meant to make life easier for developers, not users.  As a user, I might store a copy of something in the cloud for convenience, but I would never use the cloud as my main work area.

C# 4.0

Recall that C# 3.0 gave us query syntax, extension methods and the ”var” shortcut, and tried to change us to functional programmers with lambdas.  With the possible exception of LINQ, I personally have not yet encountered a situation where I thought any of those things would make my code better.

So what can we expect from C# 4.0?  Among other things, dynamic types.  That’s right, in the continuing effort to put back all the bad things we didn’t like about VBScript and C, the variant and void* is back.  For all those people who simply can’t decide how to declare your variables, you can now circumvent all pre-planning and simply write, “void myfunction( dynamic myparam )”.  Is that parameter a string?  Is it an int?  Is it a custom object?  Is it an array?  Who knows?  Guessing is half the fun!

I kid of course.  You could assume it’s an object of some kind.

I’m sure there are situations where it is more convenient to use “dynamic” than an interface.  (Just like there were plenty of occasions to use void* types and variants.)  Offhand, I can’t think of any, but I’m sure they’re out there somewhere.

The problem I see with dynamics is that, as with any “advanced” language feature that circumvents the “KISS” principle, it leaves the door wide open for the inexperienced to abuse it unmercifully.  When you go too far down that road, you end up with Perl, a language almost entirely composed of symbols.

It looks like almost all of the new C# 4.0 features were designed to improve COM Interop, which is something I don’t have much use for.  I have exactly one COM component project, and if I ever need to use it again, I plan to upgrade it to managed C++.

I do like the idea of finally having optional parameters, though.  That’s something I’d use (sparingly!), as long as it compiles down to the .NET 2.0 CLR.

The Magic Two-Faced File

I was in a store recently where the clerk vehemently declared that we should stick with XP and not install Vista until there was absolutely no choice.

But where else can you find an OS that gives you the ability to have one file with two entirely different contents? Huh?

My FTP Broke

I installed Vista Service Pack 1 this weekend. Now, I can’t seem to FTP into my web site with FileZilla anymore. I think it’s just a coincidence and that my web host’s FTP server is down for completely unrelated reasons, but they aren’t usually down this long and I’m starting to wonder…

Vista Administrator Tip

Here’s a quick Vista tip: Make sure the built-in Administrator account is enabled with a password before you go and remove your normal login from the Administrators group.

I encountered this when I started seeing dialogs asking me to enter an Administrator password, but there was no text box to type in a password and the Okay button was disabled. That makes it difficult to type in a password and perform administrator functions, let me tell you.

This came about because I decided to run as a User instead of an Administrator, as Jeff Atwood so frequently advises at Coding Horror. Running as a User basically eliminates the need to run anti-virus software and spyware detectors, which bog down the computer’s performance. So I cheerfully went to my user settings and removed myself from the Administrator group.

Then I started getting the dysfunctional password dialogs. Weird. But no problem, I’ll just add myself back to the Administrators group.

Uh, except Users can’t do that. Oops.

Anyway, to fix it, you have to boot in Safe Mode (press F8 before the shiny round Windows logo appears). Then you’ll be able to login as the Administrator with no password (even though it’s technically disabled — go figure) and then you can either add yourself back to the Administrators group or enable the Administrator account with a password so you can run as a User.

UPDATE: On a Vista Home Premium installation, I had trouble enabling the Administrator account. I finally found that typing “net user administrator /active” into the Run… dialog (from an account with admin permission) will activate the Administrator account (source).