Building Gofor

I just recently finished making Gofor, a Windows Phone 7 application that provides one-touch access to the nearest “x”, where x is a type of business (restaurant, hair salon, pub, etc.). I’m pretty happy with the result, and wanted to jot down some notes on the dev process and reflect on what went well and what could’ve been done better.

First off, I want to thank Les for helping out with the graphic design and animations for the application. Before this I’ve never really had a resource for those kind of things, relying mostly on templates / default settings for controls and layouts and the like. Having someone create visual assets that look really good really makes your applications stand out and get noticed, and I think the fun and approachable UI will be the main draw for our application. Make sure to check out Les’ other project, Nothing Ventured.

Teh Codez

From a development perspective, this is a really simple app. All it basically does is get the phone’s current location, and uses that to execute an API call against the Yellow Pages API. Now, I’m a fan of the M-V-VM pattern (especially in WPF) but for this I went with really simple button click events with standard partial “code behind” files. Given the extremely basic nature of the application, and also that it’s pretty much stateless except when paging through search results, I didn’t think it was worth the additional overhead.

This was also my first attempt at XAML Animation, using a bunch of png frames provided by Les. This was unique in that we have a looping “loading” animation that ends off with a “finished” animation. It involved signalling the first storyboard to stop after finishing the current animation loop, and then when that storyboard was finished starting the 2nd storyboard. The storyboard setup was done in xaml and the animation control in C#, although I’m sure with some fancy event binding I could’ve done most of it in xaml.

Location Services’ Non-Functional Requirements

Using the location services from the windows phone API was really easy – the hard part was all the extra stuff we had to add in order to pass certification. If your app uses location services, you need to prompt the user to enable location services when the app is first launched, and also provide a way for the user to turn off location services whenever they want. You also have to provide some descriptive text explaining exactly what you’re doing with the user’s location data. And of course because location services can be disabled by the user at any time, your entire codebase has to check for access and handle it properly if it’s disabled. I understand why this is all required, as throwing around a user’s location data can lead to some privacy concerns, but it did add another layer of complexity to the application.


The only other small roadblock I ran into was the YellowAPI itself. The API is pretty simple (only 4 endpoints) and they even provide a windows phone-specific library you can just import into your project, but there’s a few small quirks with some of the API calls that I had to figure out with trial and error. A lot of it was configuration based, but sometimes if you ask for the wrong thing it gives you unexpected results – like if you try to get more details from a business they just returned, but the GetBusinessDetails call returns 404 Not Found. Or that it ignores the name part of that query if you provide it an ID, but it still requires you to put something (I used “a”). Luckily the @YellowAPI account and team is really responsive to questions and I got most of it figured out quickly.


We do have plans for extra features, but we decided to hold back to see how popular the app becomes before investing more spare time into it. On that list we’re including: US businesses (right now we only support Canada through Yellow Pages), more & changing business buttons, and new loading animations. I also want to include a mechanism that will allow us to publish changes like new buttons and loading animations without updating the application, sidestepping the windows phone marketplace certification (which can take anywhere from 3 days to 2 weeks).

All in all, I enjoyed making Gofor. It’s currently been given to the windows phone marketplace submission gods, once it’s been released I’ll be sure to let everyone know so they can download it :P