Tutorial details

Real Time Clock NSDateFormatter | App Code for Sale | Preview

Real Time Clock NSDateFormatter | iOS Tutorial

How to create a simple real time clock

Overview PAGE TOP

Reference: http://www.geekylemon.com/WEBPROTECT-xcode4realtimeclock.htm

In this tutorial i will be showing you how to create a simple real time clock


  • 1 UILabel

Displaying the tim ein your apps gives the user general information if yo uhave hidden you status bar or a just a nice feature in your app

ViewController.h PAGE TOP

@interface ViewController :UIViewController {
IBOutlet UILabel *label;    
NSTimer *timer;


ViewController.m PAGE TOP

@implementation ViewController
-(void)updateTimer {
NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
    [formatter setDateFormat:@"hh:mm:ss"];
label.text = [formatter stringFromDate:[NSDate date]];
- (void)viewDidLoad {
    [super viewDidLoad];
timer = [NSTimer scheduledTimerWithTimeInterval:0.5 

Reference PAGE TOP


0 Comments Leave a comment

Please login in order to leave a comment.

Newest first

to your Chupamobile Account.

The Easiest way to Launch your next App or Game.

Join Chupamobile and get instant access to thousands of ready made App and Game Templates.

Creating an account means you’re okay with Chupamobile’s Terms of Service and Privacy Policy.