Administrative

Browser wars

Every so often I update my chart of the technologies people use to view my blog. The last time was back in October last year, and the chart as it looks now is very interesting. The three major browsers (Internet Explorer, Fire Fox and Chrome) are now converging at around 30% share each. Other browsers such as Opera and Safari don’t get much of a look in. However, it does look like I’ll shortly have to start noting down one or two mobile browsers distinctly. Currently mobile browsers are all lumped into the “Other” category.

Meanwhile, on the operating system front Windows XP continues to slowly ebb away. However, the fact that 30% of the visits to my blog are from a Windows XP machine is still painful to see. Vista users are also dying away and are down to about 6% now. At its current rate of decline there will be more Mac users visiting my blog by the turn of the year.

Google Analytics also has a facility to record page load times, however it is currently only reporting from Internet Explorer and Chrome at the moment. That coupled with only 3 months of data so far doesn’t make for very interesting trend watching. However, in a future update I’m sure I’ll add page load times.

Tip of the Day

Tip of the Day #9 (The Project Location Is Not Trusted)

This tip is to get a tool called ZoneStripper by James Kovaks to stop the annoying “project location not trusted” dialog box, below, appearing when you open downloaded solutions in Visual Studio.

If you download zipped source code from the web, unzip it and then open the solution in Visual Studio 2008 (and apparently VS 2003 and VS 2005 as well) you may get a dialog that says “The project location is not trusted” … “Running the application may result in security exceptions when it attempts to perform actions which require full trust.” A bit like this:

The project location is not trusted

What happens is that when you download something from the internet Windows (from Windows XP SP2 onwards) will add an alternate stream to the file called zone.identifier. If the file is a zip it will then add that alternate stream to each of the files as it unzips.

You can view this stream by typing something like the following at a command prompt:

notepad DevWeek2009_PreCon.zip:zone.identifier

You can then read the contents of the alternate stream:

What the ZoneStripper program does is delete the zone.identifier alternate stream from the file so that zone aware applications (and the OS) treat the file normally.

Note: If you unzip the files to a FAT based file system then you won’t have a zone.identifier in the first place as the FAT file system does not support alternate file streams.

Software Development

SQL Server / Visual Studio Install Order

Yesterday I paved my laptop in order to upgrade to Windows Vista. I’ve now started to reinstall everything from scratch again. However, one thing that didn’t work out was the installation of SQL Server 2005. No matter what I tried I could not seem to get it to install the SQL Server Management Studio – somehow it was convinced that it already existed. I eventually figured out why.

I’d installed Visual Studio 2008 first, and as part of that installation it installed SQL Server 2005 Express edition. The express edition does not come with SQL Server Management Studio. When I went to install SQL Server 2005 it refused to install the management studio saying that more up-to-date versions of the tools were already available on the machine. (Well, I suppose some of them were, at least the ones installed by Visual Studio 2008’s installer). Running the Service Pack 2 upgrade did not help either. It concluded that the client tools were not valid as part of the upgrade and refused to install them.

Eventually I came to the conclusion that it would be quicker, given my recent wiping of my laptop to just start afresh again and install things in the correct order. I suppose I was lucky to have that option. I am also lucky that I don’t activate Windows until I’m sure everything is installed correctly – after all I do have 30 days to activate Windows. I’d hate to have lost an activation of Windows because of a dodgy install.

So what is the installation order I’ve now used that works:

  • Windows Vista SP1
  • Windows Update (my install required 33 updates)
  • SQL Server 2005
  • SQL Server 2005 SP2
  • Visual Studio 2008

 

PLEASE NOTE: The above is what worked for me. I’ve also heard that it has worked for others too. It comes with no warranties of any kind.

If you are having difficulty installing your SQL Server you may like to ask a question on one of the many fine forums that are available for asking questions of that nature. I tend to hang out on Code Project and may be able to help there. If I’m not around then one of the many other great members can possibly help you on their database forum.

Software Development

Installing SQL Server 2005 on Vista

Perhaps this is not so much an issue with installing SQL Server 2005 on Vista, but of the way I install SQL Server 2005 on Vista, or even more accurately install it on my laptop on Vista.

A SQL Server will expect to run constantly on the machine that it is installed on. However, not on my laptop. I generally have SQL Server turned off on my laptop because it uses resources that it does not need. I don’t frequently use SQL Server on my laptop but I do need it sometimes. Because of this, during the installation I customise it so that the SQL Server services do not start up automatically as they normally would.

There is a slight problem with this approach I’ve discovered when installing on Vista. SQL Server 2005 came out before Windows Vista and they don’t actually get along out of the box. You have to install SQL Server 2005 SP2 (or so several dialogs claim) before you can start working with SQL Server 2005 on Windows Vista.

At the end of the process for installing SP2 it will let you know that admin users on the Vista box will not be admin in SQL Server unless you are explicit about which users to add. It then launches a “SQL Server 2005 User Provisioning Tool for Vista” to allow you to set up the admin users. However, if the SQL Server services are not running it cannot do this – the User Provisioning Tool will run, but when you apply the changes it will popup an error message and quit. So, it would seem that what I should have done is let the installer get on with running SQL Server 2005 when it finished so that the admin users could be set up. However, I didn’t and it failed. So, without any users set up on the SQL Server I could not log in.

After hunting around on disk for this User Provisioning Tool I discovered that the SQL Server 2005 Surface Area Configuration tool will allow me to launch the tool by pressing the “Add New Administrator” link in its dialog. So, with the SQL Server services (all of them indicating in the User Provisioning Tool, in my case the Database Engine and the Analysis Services) running I add myself to the list of users, click OK and…. A moment later everything seem to work. There is no confirmation, the dialog just goes away without any error messages. To test it worked I opened up the SQL Server Management Studio and attempt to log in. It works. I’m happy.

Now, finally, I go and limit the amount of memory I’m prepared to allow SQL Server to use. See my post on managing SQL Server’s memory usage. It is a laptop after all…

Update:
Please note that this was using SQL Server 2005 Developer Edition.

Misc

Aarrgghh!! Accidentally pressing the Caps Lock key

I keep pressing the Caps Lock key accidentally. I don’t know why, but I do. I think it is the most despicable key on the keyboard, but I am not willing to go to the measures that a former colleague did. He hacked the key off his keyboard.

There are ways to get notified that the button has been pressed accidentally. In the control panel there is a setting that means that each time a “lock” key (Caps Lock, Num Lock and Scroll Lock) is pressed you get notified with a beep. The setting (known as “Toggle Keys”) is part of the keyboard accessibility options.

There are two routes to the setting. The Classic route and the modern route (it depends on how you’ve got your Control Panel configured).

Modern Route

If you are taking the modern route (the default) you need to open the control panel and select “Ease of Access”

Vista Control Panel (Modern)

Then click the link that says “Change how your keyboard works”

Vista Control Panel (Modern)

Classic Route

If you are taking the classic route you need to select the “Ease of Access Center”

Vista Control Panel (Classic)

Then click the link “Make the keyboard easier to use”

Vista Control Panel (Classic)

Finally

Both routes will eventually lead to the same screen. You need to ensure that “Turn on Toggle Keys” is checked (ticked). Once the setting is turned on you can “Apply” or “Save” the settings.

Make the Keyboard Easier to Use

Misc

Useless Error Message

Exception Processing Message 0xc0000013 Parameters 0x75BE023C 0x8343FCBC 0x75BE023C 0x75BE023C

Pointless error message

Well here’s a pointless error message from Microsoft Powerpoint 2007 running on Windows Vista.

What actually happened is that I picked from the list of recently opened files a presentation that was saved to a USB key which is no longer present. While the dialog title bar does give useful information to the user, the main message is filled with useless rubbish as far as a user is concerned.

Pressing cancel doesn’t immediately help – It just repeats the message. You have to click cancel a fair few times before it eventually tells you something useful – Such as it can’t actually find the file with the given path name.

Why wasn’t the user told immediately that it couldn’t locate the file instead of being presented with a bunch of hex?

Tags:

Misc

Configuring Clear Type

For most LCD monitors turning on Clear Type makes the fonts look much smoother and easier to read. For some, however, it makes the font look awful. This is because Clear Type works by operating on the sub-pixel level. It tweaks the individual red, green and blue dots on the monitor to improve the resolution of the text. However, not all monitors are made the same and the positioning of those dots may make the text appear fuzzy round the edges as the text is rendered incorrectly for the monitor.

Help is at hand. You can configure the way Clear Type is rendered by using Microsoft‘s ClearType Tuner, a four step process to setup ClearType for your monitor.

NOTE: This was rescued from the Google Cache. The original date was Monday 29th May, 2006.