iOS

To translate or not

June 4th, 2012 posted in Objective-C

Creating a lot of apps have taught me some important lessons.

One being also keep in mind that you may have to translate your app.
I tent to use NSLocalizedString for every string I write in code just so that when its needed I can easily translate the app. Which has been a time saver many times.

I don’t really use the multilingual NIB (adding localised versions of NIB files). Because, especially in early stage if development, you have to maintain two or more files. I just do it in code and adjust the UI if needed.
Getting the size of a string is fast en easy.

Retrieving files for document directory

March 21st, 2012 posted in Apps Developement Objective-C

Ever had the need to retrieve data stored in the document directory of you iOS application. Well surprisingly Xcode can help you.
Read the rest of this entry »

Deprecating uniqueIdentifier is a good thing.

March 9th, 2012 posted in Apps Developement Objective-C

Since iOS 5 was first in beta many developers started complaining about the fact that the [[UIDevice currentDevice] uniqueIdentifier] got deprecated.
Some developer even stated that is was the worst idea Apple ever had.

Well I don’t agree with them, this is about the smartest thing they did. If only for the privacy of the user.

Read the rest of this entry »

Running iOS 5 build apps on the orignal iPhone, iPod touch and iPhone 3G

December 27th, 2011 posted in Developement Objective-C

With the introduction of the iPhone 3GS Apple made a major switch in processor architecture, they went from armv6 to armv7.
Now that we have all update to Xcode 4 with iOS 5, Apple seems to be of the opinion that you can drop support of the armv6 architecture.

Well this isn’t always the case, especial if you want to keep support for those device that can run iOS 4.*. Luckily there is an easy solutions for this.

Read the rest of this entry »

JSON parsing

August 23rd, 2011 posted in Web technology

Many people have written about parsing JSON data on the iPhone, but why use JSON and not XML.
Well this has to do with overhead, JSON is smaller in it’s mark-up then XML thus it will take less traffic on the cellular network.

But there are some drawback in using JSON, since there is no real strict way of checking the model. Like DTD is for XML.
Read the rest of this entry »