Wix: Installing a shortcut to a URL with an icon

For months now an installer that I created using the InternetShortcut tag has been without a nice icon.

I decided to trawl the web and work out how to create a shortcut that could contain an icon.

It turns out you can actually use a standard Wix Shortcut IF you perform a few steps. First you need to define an icon like so:

<Icon Id="Shortcut_Icon.ico" SourceFile="<path to icon>" />

Note: The Id of the icon has a .ico extension. This is important as Wix does not generate a correct shortcut if this is not present.

Then, you need to setup a property which contains the URL you wish to have the shortcut launch:

<Property Id="Shortcut_Url" Value="http://the.url.you.would.like.launched" />

Finally, you need to create a shortcut that uses both the icon and the URL property:

<Shortcut Id="SampleShortcut" Directory="DesktopFolder" Name="Sample" WorkingDirectory="SampleDir"
Description="Launches Website." Target="[Shortcut_Url]" Icon="Shortcut_Icon.ico" />

The result is a shortcut that will launch the users default browser to the specified URL.

ArcGIS Runtime for .NET – Observation #1

When coming from the ArcGIS Engine world one of the first things that catches your attention with ArcGIS Runtime for .NET is the fact that you do not need to install it on a client device.

You merely need to include the Runtime files with your application.

This may seem like a small thing but when you are dealing with maintaining software on thousands of client devices it is awesome!!

Not having yet another pre-requisite (and a 500MB+ one at that) really helps deployment.

5k a day

For a few months leading up to the New Year I had thinking about doing 5k a day and not drinking alcohol for the month of January. It seemed like a good way to kick start getting fit again and I had read that a month without any alcohol really helps your body.

So, on the 1st January, my wife and I started doing 5k every day. Notice I didn’t say running 5k as it was nowhere near that!

Now that we half way through the challenge and I have a handle on it I’ve decided to write this blog post.

Firstly, starting on the 1st Jan was a REALLY bad idea. Not only was the night before busy but we still had things we wanted to do on New Year’s Day.

Next, 31 days of doing 5k a day takes time and focus. There are many things that can get in the way of you spending up to an hour getting the task done.

At this point though we are half way done and my times have went from around 60 mins to 43 minutes. This is mainly due to picking up the distance that I am jogging and my goal it to be jogging at least half the distance by the time this challenge is all said and done.

Map My Fitness (I use map my ride) applications and an iPhone is all I needed to track some good information on how I was doing. I do intend on getting the Apple Watch when it comes out though. Mainly because I want one but it does track your heart rate. Keeping that is the right range would be nice.

ArcGIS Runtime for .NET

For the past 10 months my working life has been consumed by implementing functionality in and around ArcGIS Runtime for .NET. Our product does much more than just be a front end for a map but having that map nod working against the API has been a big part of what we have been doing.

I have had to remain fairly tight lipped on what we have been doing as we signed a NDA bit know that runtime for .net has been released I can start to talk about things more.

For the past year or so know it is plainly evident that Esri has upped their game. I always liked what the Silverlight/WPF/.NET team have been doing but the work that has been put into the core c++ runtime is impressive.

Over the course of the next few months I will blog on all things runtime so watch this space.

Rangers FC

I am a Glasgow Rangers fan. Have been since the day I was born, I just did not know it yet!

The past few years have been torture for any Rangers fan but I believe this year has been the worst so far. We successfully navigated the lower two leagues with relative ease and 50k watching in Ibrox every other week.

Everyone knew that this season was going to be difficult. Hearts and Hibs being in the championship adds an extra dimension to a league that was already going to be challenging bit let’s face it, the wage bill at Ibrox should be making these games a cake walk.

There are a few shining lights out of the whole thing though.

Lewis MacLeod is one of the best Rangers prospects I have seen. He’s the best player on the park right now and I hope he stays fit and stays at he club.
Nicky Clarke is fast and has an eye for goal, the missed him up front against Hibs and will be glad when he comes back
Ian Black gets a bunch of stick but he is consistently getting talked about a man of the match and I agree.

Kris Boyd was a beast for us before he left and I respect that but he is not firing right now. Take him off and put Clarke and Templeton up front. Their pace and ball skills will get goals and scare most defenses.

Mohsni is a liability but that’s ok if you pair him with a decent defender. Zaloukas looks composed sometimes and downright scary at other times. I don’t know how hearts did not leak goals. He’s not had much game time though.

The most scary thing about rangers right now is not on the park, it’s who is running it. Ibrox is a ghost town compared to other years as plenty of fans are boycotting the games. The club managed to blow all of the IPO money with some of it being dubious at best.

I would really like for Rangers to be like Hearts setup where the fans own the club and there is a fan group that decides matters. The club is never going to be a European giant if it stays in Scotland, the money is not there so any business owner is doing it either for the love of the club or, like the most recent set of management, to make money. I believe making tangible money is impossible so the owner and the well being of the club are at odds.

Hopefully a true rangers fan (where is Dave King in all of this?) steps up mad does the right thing.

Esri Dev Summit 2014

I am writing this as I head out to the Esri Dev Summit in Palm Springs, CA. Its been a few years since I have been able to attend so I’m looking forward to a week of learning and interaction with other Esri developers.

Things have changed in the past few years. SilverlightFlex has been replaced by HTML5 and native runtime applications and Esri in particular have focused on Devices.

In the mobile world the company I work for (TCT) has focused on using ArcGIS Engine. Its the platform that made sense for our primary customer base of Utilities.

Things are changing though and Runtime for WPF is a viable platform especially when you consider the Offline capabilities that will be available by summer.

Like many other software companies we have heavily invested in ArcGIS Engine over the years. Things like standard controls for viewing attributes and helper functions to make using the API for our needs easier. This same investment has to be repeated for ArcGIS Runtime. Doing this is welcome as it is the life of a software developer but it also lets us re-think how we do things based on what we have learned over the years.

I look forward to talking with people and seeing what everyone is up to.

Fixing Orphaned Users in SQL Server

One of the first tasks when loading data from a backup is to match up the
users in the database with the ones defined in SQL Server. Getting data
from clients continually and having to do this you would think I would
remember it but unfortunately no, I have to lookup it up each time.

So this one is mainly for me!!!

EXEC sp_change_users_login 'Update_One', 'john', 'john'

Rangers FC Tribunal

I know that this is primarily a technical blog but I have hobbies outside the software world. As Scott Hanselman says, follow the whole person

One of them is following football (soccer) and especially my home team Glasgow Rangers. They have been through a turbulent year with some of it being deserved and some..not.

Today a tribunal decided that although Rangers used EBTs without informing the Football Association their punishment should be a fine rather than getting stripped of titles. This seems like a fair decision to me and I am glad that yet another cloud hanging over the club is being lifted.

For too long now matters outside I what happens on the pitch have dominated the newspapers in Scotland. After the dust settles from this decision it’s time to start watching the beautiful game without interruption again.

Ofcourse for it to be beautiful our defense needs to stop leaking goals!!!

Back to work!

Remote Working

A bunch had been said about Yahoo, more specifically Marissa Mayer, changing their policy on Remote workers. I am sure that it was done for reasons that made sense at the time but it is the wrong call.

I have worked remotely for almost 8 years now after working in an office for 8 years and I can say this, in most areas working remotely wins. This is especially true for software companies where we use online tools for collaboration.

From my perspective most people working remotely do longer hours and are hyper aware of making sure that they get their work done. If some people in Yahoo have not been doing their job then they should have been fired regardless of working remotely or not.

Making people come into an office sounds like a knee jerk reaction to me. Breaching contracts or at least promises in the process is just wrong.

Microsoft, Facebook and Google are just about to get some good employees and Yahoo deserves it.

Dark Room

I have been getting up early again for the past few days and reverted back to an application I have been using for a while.

The application is called Dark Room. It is a c# word processing application that has a black background and green text. I know it sounds strange but when your eyes have not adjusted to the light yet this app is wonderful.

I use it for about 30 mins until I can brave using normal bright tools like Outlook. I then simple copy the email(s) I have been writing into new outlook messages and send them. Done.

I stopped doing this a while back as it was hard to type properly but with my new laptop and it’s backlit keyboard (just bright enough – not too bright!) it makes sense again.