preload
Jun 18

When creating an application it is often a good idea to add support for localization so it’s easy to update and add new languages to your application. For the PinCodeKepper app I only need to localize the text since all icons and graphics used are international with no text attached.

Windows Phone 7 have pretty good localization support where you add a resource file for each supported language and the application will select which resource file to use based on regional settings on the device.

This article describes how I added support for localization on the PinCodeKeeper app.

Set up resources

Continue reading »

Tagged with:
Jun 14

The add new pin code functionality (completed in previous article) was the last main functionality for the PinCodeKeeper and the time has come to start using real data instead of mock up data. I will now implement Isolated Storage so that I can save/store new pin codes, retrieve all saved pin codes and delete pin codes from the storage.

The first thing I do is to add a new class that I call IsolatedStorageUtil.cs, this class will contain all functionality I need for saving, retrieving, deleting and some other utility methods. To use the DataContractSerializer you must add a reference to System.Runtime.Serialization.

You can see my IsolatedStorageUtil.cs class below.

using System;
using System.IO;
using System.IO.IsolatedStorage;
using System.Runtime.Serialization;

Continue reading »

Tagged with:
Jun 09

In this article I will create the “Add New” Pin code screen for my PinCodeKeeper WP7 app and I need to extend the earlier created Pin code card Custom Control. The Pin code card custom control displays a grid with coloured cells and numbers.

When adding a new pin code I want the Pin code card to display a grid with coloured cells, but no numbers. The user must be able to click on a cell to enter a number in it. I decided to add some very simple animation when the user click a cell. The cell will increase it’s size while positioning it self at centre in the top. This will be animated while the coloured grid fades out with a black colour.

Numeric keyboard

When the cell is in position I want a numeric keyboard to be displayed, I didn’t like to out of box options so I decided to make a NumericKeyboard Custom Control. I kept this very easy so I just made a custom control and added a button for each key on the numeric keyboard. I also created a delegate and a event handler with custom EventArgs so that the screen or control using the NumericKeyboard can hook up to keyboard pressed events and the pressed key value.

Continue reading »

Tagged with:
May 31

I’m working on the PinCodeKeeper Windows Phone 7 app and in this article I will walk you through how I made the Pin code card screen with a custom control to display the pin code card. I will continue from where I left when I previously completed the Pin code list screen.

The Pin code card screen will display the name of the card and a matrix with numbers on a coloured pattern. For the matrix that represents the good old pin code card I will create a custom control.

PinCodeCard custom control

To create a custom control right click in your Solution Explorer and select “Add” –> “New Item” –>”Windows Phone User Control”, name it PinCodeCard and click “Add”.

Continue reading »

Tagged with:
May 29

In the previous article I defined the project structure for the PinCodeKeeper WP7 app, in this post I will write the code to complete the Pin code list screen.

Creating the GUI

I start by creating GUI for the “PinCodeListView.xaml”. The GUI for this view contains a header, a list and an application bar.

Below you can see the xaml code for the “PinCodeListView.xaml”, notice the data binding capabilities I use for the pin code list. I also needed to add some icons for the application bar buttons. I found a free set of Mono Icons 32×32 that suited my app. I created a new folder called “Images” and added “plus32.png”, “questionbook32.png” and “stop32.png” to that folder. Remember that the images must be set to Build action: Content and Copy to output directory: Copy Always.

Continue reading »

Tagged with:
May 29

In this article I will go through the steps for creating and structuring a Windows Phone 7 app in Visual Studio 2010. In an earlier article I did some sketching and analysing for the PinCodeKeeper app and I will now start developing this application.

I will not go through the steps for installing Windows Phone Developer tools, if you have not all ready installed these tools have a look at this article: Installing Windows Phone Developer Tools. I am using Visual Studio 2010 Ultimate with the latest Windows Phone Developer Tools installed.

Create a Windows Phone project

In Visual Studio 2010 select “New project” –> “Silverlight for Windows Phone” –> “Windows Phone Application”. Then give the project a name and click “OK”, I named my project “PinCodeKeeper”.

Continue reading »

Tagged with:
May 29

When starting developing a new mobile app it is always tempting to jump directly to your favourite IDE and start developing, but do yourself a favour and spend a few minutes planing what you are going to develop. This will most likely save you a lot of time later on.

I’m creating a very simple Windows Phone 7 app called PinCodeKeeper and as the name states this application will keep your pin codes.

Sketching

It’s always a good idea to start sketching the wire frames for your application. I like to just make some easy and not very detailed wire frames covering the most important parts of the application. The most important at this phase is to identify the functionality you want the app to contain. These sketches are also very good to use when discussing the app with potential users/customers.

Continue reading »

Tagged with:
May 06

The Norwegian Windows Phone Developer Community (WPDC) will have a meetup in Oslo 26th May.

It’ s now under three weeks until the next quarterly meetup for WPDC and the meetup will as usual take place at The Scotsman pub in Oslo. The evening will be filled with two great sessions held by Einar Ingebrigtsen and Gøran Hansen. There will also be a quiz with great prices held by our sponsor Glasspaper AS.

Einar Ingebrigtsen is a Microsoft Silverlight MVP and creator of Balder (a 3D engine for Silverlight, Windows Phone 7, XNA and OpenGL). He will talk about XNA, Silverlight and how to create 3D graphics for Windows Phone 7.

Gøran Hansen is a Microsoft Client Application Development MVP and Microsoft Regional Director. He will talk about Domain Driven Design (DDD) and how this can be used for mobile application projects.

Continue reading »

Tagged with:
May 06

Quite a while ago when I started doing Windows Phone 7 development I was looking for a good book to start with and I bought the Beginning Windows Phone 7 Development book written by Henry Lee and Eugene Chuvyrov. This turned out to be a very good choice, the book covers the most important parts of Windows Phone 7 development, filled with good code examples and is well written.

The book consists of two parts, 19 chapters and 458 pages.

Part 1: The Essentials of Windows Phone 7 Application Development

  • Introducing Windows Phone 7 and the Windows Phone Platform
  • Building Windows Phone 7 Applications
  • Using Cloud Services As Data Stores
  • Catching and Debugging Errors
  • Packaging, Publishing and Managing Applications

Continue reading »

Tagged with:
Apr 19

Occasionally I will write some articles exclusively for DZone, this time I have written a series of 3 articles covering push notification for Windows Phone 7 using SQL Azure and Cloud services.

Part 1/3

Covers how to create the SQL Azure tables that will be used to store notification subscription information and how to create a WCF Cloud service that communicates with the SQL Azure database and pushes toast notification to subscribing phones.

Read the article at DZone: Push Notifications for Windows Phone 7 using SQL Azure and Cloud services – Part 1/3

Continue reading »

Tagged with:
Subscribe to my feeds Follow me on Twitter
DZone MVB