Voices That Matter

Date and Time

iPhone Developer Tips Stats:
Past 30 days - Pageviews: 88,424 Visitors: 61,675
Thank you everyone! Let's shoot for 100,000 by May. Pass it on...



Date Formatter Examples – Take 4: Setting Locale

A reader recently wrote and asked how to show a date output in a different language. By default, the NSDateFormatter will use the locale set on the device, so no code specific locale changes are required if you want your app to display in the current locale.
However, if you need to display a date [...]

Cocoa, Date and Time

Determining Elapsed Time

I recently wrote a short block of code to display an activity indicator while waiting for an image to be written to the iPhone camera roll. The problem I ran into is that the time to write the image file varies, depending on the image size. In some cases the activity indicator would be visible [...]

Date and Time

Date Formatter Examples – Take 3: Date from String

While working on an iPhone application recently, I needed to convert a date read from an XML stream that was in the following format: 20081122 to a nicely formatted string for display on the device: Saturday November 22, 2008.

Cocoa, Date and Time

Date Formatter Examples – Take 2: Format Strings

In the first post on working with dates several of the examples use the “old style” date format syntax. The examples work, however, I want to show an additional example that uses the ICU (International Components for Unicode) library for format strings.

Cocoa, Date and Time

Date Formatter Examples – Take 1: NSDateFormatter

Sometimes all you’re really looking for is a basic chunk of code to get something done. For example, I was working on an application yesterday and needed to display the current date in text format: October 29, 2008. A simple concept for sure, however, with the many nuances of date formatters, it takes some time [...]

Cocoa, Date and Time