iPhone StopWatch Pro 2.0 Released

An easy to use iPhone stopwatch application that can record lap times and generates log files.

Time your laps

Version 2.0 highlights

  • Major improvements to the look and feel of the user interface with a nice sporty theme!
  • It is now possible to mail your log files.
  • You can now use iTunes to download all your log files.

For a full list of features check the StopWatch Pro product page.

    Mixing iAd and AdMob

    Introduction

    Is it a real fact or just a rumor…I’m not sure yet…but:

    • iAd is not yet available in all countries but has a higher earning per impression and click-through
    • AdMob is available in almost every country but with a lower earning rate per impression and click-through

    So why not just combine both?

    You can check the resullt with the free stopwatch application:

    Or you can download a zip file from the project to use as a starting point.

    Or you can visit the repository on Github.

    It may look like a complex task but it is rather easy to accomplish. I will not fully explain how to setup iAd neither how to setup AdMob, but I will provide the directions on how to make both advertising platform work nicely together so you can maximize your earnings.

    More >

    Overriding Objective-C description

    It is good practice to to always override the description method which is part of the NSObject protocol. Compared to other language it is equivalent to:

    • C# has ToString()
    • Java has to toString()

    This description method will return a string representation of the object it is send to. Overriding this method can make debugging a trivial task.

    Lets look at an example for a class Person which has 3 properties:

    • NSString *firstName
    • NSString *lastName
    • NSInteger age

    Inside the .m implementation file of this class Person we only need to give an implementation to description:

    -(NSString *) description {
         return [NSString stringWithFormat:@"Person: %@ %@ - %d", self.firstName,
                                                                  self.lastName,
                                                                  self.age];
    }

    Now it is very easy to log this description inside the console by calling:

    NSLog(@"%@", person);

    And the output will look like:

    2011-12-14 20:23:53.508 Description Example [2705:b303] Person: John Doe - 41

    It is even possible to directly call the description method inside the GDB console by using po:

    (gdb) po person
    
    Person: John Doe - 41
    
    (gdb)

    Happy bug hunting!

    iOS 4 Core Data Tutorial: adding persistence to the Contacts Application

    In this tutorial we will be adding persistence to the Contacts application. This application was discussed in a previous post Sample iPhone Application: Contacts Tutorial. I strongly advise you to start from the provided project contacts.zip to easily follow the source code.

    This time we will be using Core Data. Core Data is the ORM implementation from Apple. ORM stands for Object-Relational Mapping and is a technique to map incompatible data type system. In this case mapping Objective-C objects to the relational database SQLite.

    The tutorial contains following main sections:

    To see the full application feel free to download the source code: contacts_orm.zip

    Or try the application on the App Store!

    More >

    iOS 4 SQLite Tutorial: Adding persistance to the StopWatch application

    In this tutorial we will be adding persistance to our StopWatch application. We will persists the different timings inside an SQLite table. SQLite is an embedded, relational database management system, in short RDBMS. It is called embedded because the database is provided in the form of a library. This library is then compiled inside your application, so your application is hosting the database. For example MySQL is not embedded, because it is installed as a separate application that behaves as a server.

    The contents of this tutorial are:

    As always it is possible to download the source code from this tutorial: StopWatch_SQLite

    If you like this tutorial check out the application itself and increases my iAd revenue by clicking an advertisment! :lol:

    More >

    Setting the title of the UINavigationBar back button

    When using a UINavigationController the UIBarButtonItem located on the left of the UINavigationBar, in short the back button, will contain a default title. This title is taken from the view that pushes the new view, containing the back button, on the navigation stack. It will often happen that this default title is too long.

    How to change the title?

    Before the new view controller gets pushed on the stack the title of the current view needs to be set! Lets explain this with a small piece of code:

    DetailViewController *detailViewController = [[DetailViewController alloc]initWithNibName:@"DetailViewController" bundle:[NSBundle mainBundle]];
    [self setTitle:@"Your new back title"];
    [self.navigationController pushViewController:detailsViewController animated:YES];
    [detailsViewController release];

    As you can see in the above snippet, right before calling pushViewController the title is changed.

    Now if the back button is pressed we need to reset the title again of course. This can be done inside the method viewWillAppear:

    - (void)viewDidAppear:(BOOL)animated
    {
         self.title = @"Reset the old title";
    }

    I hope this helps you out! If you have a more elegant solution please share this with us!

     

     

    ActionNotes updated to 1.2.1

    A few weeks ago we featured a review of ActionNotes by Netwalk Apps.  Last week an update was released. This update introduced many productivity and stability improvements. Lets highlight the important new features:

    • It is now possible to sort notes on date or alphabetically
    • Every single node is now indexed and this allows for a simple text search
    • Sections that group related notes now also show the name inside the index
    • Integration with Dropbox to backup all your notes!

    As always a single screenshot says more the words:

    Action Notes Featues

    Features introduced in Action Notes 1.2.1

    These improvements were also on the top of our list after the previous review…did the developer check this website? :)

    iOS 4 Training

    apptite is offering a iOS 4 hands-on training starting from Monday June 27 until Thursday June 30 in Leuven. The training will be organized around 4 modules, you can choose which modules you want to attend, this allows you to create a custom tailored learning path!

    The training consist out of 4 modules:

    • Basic Module
    • Essentials Module
    • Advanced Module
    • Appstore Module

    Check out iOS 4 – Training for more information.

    Creating custom iOS UIButtons

    Introduction

    Not only functionality is the driving factor of good applications, also the look and feel is very important. This tutorial will guide you through some steps of creating custom buttons, this are buttons with a custom look and feel. The starting point of this tutorial is the StopWatch application. You can download the sample project file: StopWatch

    What will we do:

    If you like this tutorial check out the application itself and increases my iAd revenue! ;)

    More >

    4. Editing UITableView (Sample iPhone Application: Contacts Tutorial)

    The fourth and last part of the UITableView tutorial will introduce the basic principals on how to add new contacts to the table and how to delete and modify existing contacts. The design will be the same as inside the Contacts application of Apple:

    • Press the add button to start creating a new Contact, this will also show the details view of a contact
    • Select a contact to show the details view and start modifying the contact, when finished press Done or Cancel
    • Swipe to delete a contact or press the “Delete” button inside the details view

    We will now start by creating the detail view. Add a new file to the project, the specifications for the new file are:

    • File name should be DetailsViewController
    • It should be a subclass of UIViewController
    • A xib file needs to be created to layout the user interface
    File Template

    Select the UIViewController template

    File Options

    Enable the creation of a xib file

    More >