Archive

Posts Tagged ‘iphone’

iPhone Note #10: Creating Custom Settings

September 4th, 2009 rupert Comments off

settings-overview.gif

1. Create a directory on your desktop, name it “Foo”

2. Download this Sample_plist.txt and place it inside foo. Name it as Root.plist

Foo/
Foo/Root.plist

3. Rename Foo to Settings.bundle

Settings.bundle/
Settings.bundle/Root.plist

4. Drag it to your project.

settings-bundle.gif

5. To retrieve a value from the settings.. For example, if we want to retrieve if the “enabled” switch is on or off?

NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
BOOL b = [defaults boolForKey:@"enabled_preference"];
Categories: iphone Tags:

iPhone Note #9: Sending or Uploading over HTTP Post

August 18th, 2009 Rupert Comments off

In this tutorial, we would use an Objective-C Library: ASIHTTPRequest, which abstracts the complexities of using NSURLConnection

http-final.gif Read more…

Categories: iphone Tags:

iPhone Quick Tip #2: Creating Objective-C Class Diagrams Instantly

August 18th, 2009 Rupert Comments off

Omnigraffle provides a quick and dirty class diagram when you open your XCode projects. Very cool and saves you a lot of time than using VISIO. Read more…

Categories: iphone Tags: ,

iPhone Note #8: Exporting Oracle to SQLite3

August 16th, 2009 Rupert Comments off

Since I’ve been working most of my time with iPhone Dev for the last couple of months, I thought it will be worthwile to post how to import files to SQLite3. In a nutshell, use MesaSQLite’s IMPORT function. It will save you a lot of time. Now it is up to you how to export into a CSV or TAB delimited file. For Oracle, I used SQLDeveloper. For other databases, such as MySQL or Postgres, I’ve used Navicat. Read more…

Categories: iphone, oracle, sqlite3 Tags: , ,

iPhone Note #7: TableView as Single Selections

August 14th, 2009 Rupert Comments off

Today, I came up with a generic UITableViewController that allows single selections.

Part 1: Creating the view controller..

1. File -> New File -> UIViewController subclass. Check the checkbox UITableViewController subclass.

CheckListTableViewController will be referred to as the controller from here on..

2. The controller will accept:

a. NSArray *array – which holds the items.
b. NSString *title – title of the selection.

Read more…

Categories: iphone Tags: