"Design is a plan for arranging elements in such a way as best to accomplish a particular purpose" — Charles Eames

This little snippet will let you show the network activity indicator using ShowActivityIndicator(); and hide it with HideActivityIndicator();.

#define ShowActivityIndicator() [[UIApplication sharedApplication] setNetworkActivityIndicatorVisible: YES];
#define HideActivityIndicator() [[UIApplication sharedApplication] setNetworkActivityIndicatorVisible: NO];

If you work with network in your app, then this little code will be an invaluable asset. This will save you a lot of retyping. Just put this in a header file that will be imported in all your files, Constants.h for example.

iOS applications use Cocoa classes, and these classes use the Objective-C programming language so one must know Objective-C if he/she does wish to develop iOS apps. We all know shifting from a loss, non-strict programming language might find iOS’s syntax seem strange and difficult. Don’t worry, this strangeness and difficulties will give way to an elegant experience programming in iOS and I am sure that everyone will appreciate the meticulous language to become an MVC methodologist.

Class @interface and @implementation
iOS separates a class into an @interface and @implementation. An interface declares instance variables, properties and methods. It is a standard C header file and doesn’t provide any method definitions. The implementation, however, contains the method definitions for the class and this is the place where you synthesize the properties. It is the file in a .m extension.

Creating a project with Objective-C Class file
We will create an example project using an Objective-C class and IBAction. First, create a View-Based Application project and name it ClassAndIBAction. After creating the project, single-click the ClassAndIBAction folder and create a new Objective-C Class file. Go to File > New > New File or create the file by pressing Command + N (⌘ + N) buttons …

iOS is one of the most known programming language today in the mobile industry. The first iPhone was release date back June 2007 and has 350,000+ apps as of January 2011. Certainly, it is the most interesting mobile platform to date, and in the release of iOS SDK 4, things just got better.

Things you need
Before continuing, make sure to note all of this requirements. For starters, you’ll need an Intel-based Mac running Snow Leopard (OS X 10.6.7) and an Xcode 3.2.5 or preferably Xcode 4 (I am using Xcode 4).

To download the SDK, you’ll need to register first in the iOS Developer Program. Apple requires signing up before you’re allowed to download the iOS SDK.

To sign up, go to http://developer.apple.com/devcenter/ios/index.action

As you can see on the picture, download of Xcode is limited to version 4. There are two (2) ways to obtain the IDE, one way is to register as an iOS developer and pay $99/year for the standard program, and $299/year for the enterprise program.

Note: The …

Pages

Copyright © 2010 - 2013 Studio Villegas. All Rights Reserved.