How To Get 10,000,000+ Downloads In The iOS App Store (For Real!)

It’s always informative and inspiring to hear from successful iOS app store devs.

Just last week I posted an excellent interview with Calvin Carter who’s company Bottle Rocket Apps has won iOS development contracts with companies such as Disney and BMW (and produced some great apps distributed under their own brand too).

Here’s another great resource – a podcast – with the founders of two development companies who’s apps have so far combined for over 10 million downloads.

They are Colin Plamondon the CEO of Spreadsong (you are most likely familiar with their Classics book reading app) along with Rishi Modha and Anirudh Sharma from Fliplab  who have created many different popular apps (such as the (in)famous Talking Gremlin).

I’m usually not a fan of developer podcasts – but this one is not too long at just over 1/2 an hour and they really get into things talking about their app store successes, and failures. In this initial episode they reveal how they were able to get an edge on the competition and get their apps that much needed initial exposure.

You can subscribe and get the recording on iTunes (Free) here.

You can read further details – and listen in browser on the official announcement page here.

A very revealing and inspirational talk.

[via iOS Design Weekly]

©2011 iPhone, iOS 4, iPad SDK Development Tutorial and Programming Tips. All Rights Reserved.

.

DeliciousTwitterTechnoratiFacebookLinkedInEmail


Open Source: Customizable iOS Calendar Component With Landscape Orientation Support

I’ve mentioned open source libraries in the past providing calendar components such as the multi-purpose Tapku library.

This component is somewhat different, and aims to make up for some of the shortcomings of those other components.

Through the Three20 library this calendar control can be styled, and a default stylesheet is provided which can easily be modified and customized.

Also, this component adjusts for the landscape orientation unlike other components designed to be like the calendar within the iPhone’s calendar app.

The component is from Componentix, and can be found on Github here:
http://github.com/vgrichina/ios-calendar

A great component if you are looking to add a calendar into your app, and want custom styling.

©2011 iPhone, iOS 4, iPad SDK Development Tutorial and Programming Tips. All Rights Reserved.

.

DeliciousTwitterTechnoratiFacebookLinkedInEmail


Example: Using The Facebook Open Graph Beta API To Add To A User’s Wishlist On iOS

I’ve noticed quite a bit of interest in tutorials on utilizing the Facebook iOS SDK.  In the past I’ve mentioned this beginners tutorial on using the Facebook graph API, and this slightly more advanced tutorial on uploading videos with the facebook graph API.

This new example uses Facebook’s Open Graph Beta API and provides a demonstration application where users can take a photo of a product, and upload that picture to the Facebook page while first storing the data to a backend server.

You can find this example on Github here with further instructions:
https://github.com/facebook/wishlist-mobile-sample

To run this example you will need to drag in the FBConnect folder of the Facebook iOS SDK into the Xcode project, and you will need to create a Facebook app with a unique ID.

A good example if you want to learn how to use Facebook’s Open Graph API.

 

©2011 iPhone, iOS 4, iPad SDK Development Tutorial and Programming Tips. All Rights Reserved.

.

DeliciousTwitterTechnoratiFacebookLinkedInEmail


Open Source: Multipurpose iOS Developer Library With Many Utility Features

I’ve mentioned some great multipurpose libraries such as the massive Cooliris Toolkit and the well documented Three-20 replacement library Nimbus.

This library is in the same vein as those libraries providing a large number of useful classes.

This library provides a useful collection of utility macros, helpers for core data, numerous extensions extending basic iOS SDK classes, and numerous user interface components, and more.

The library is iBoost Framework from Rapture In Venice (who’s XML parser I mentioned earlier) and you can find it on Github here:
https://github.com/ZaBlanc/iBoost

On that page you will find a good amount of documentation, and there is further documentation provided here: Part 1, Part 2

Looks like another very useful multi-purpose library for iOS development.

©2011 iPhone, iOS 4, iPad SDK Development Tutorial and Programming Tips. All Rights Reserved.

.

DeliciousTwitterTechnoratiFacebookLinkedInEmail


Open Source: New XML Parsing Library With A Highly Readable Easy To Maintain Syntax

There are many different open source XML parsing libraries for the iOS platform, several were in the previously mentioned XML parser performance guide.  For those interested in doing things without making use of an outside library I mentioned some reusable classes for XML parsing.

I’ve actually found out about, and had some other XML parser libraries submitted, but none of those libraries really provided anything different from what was already out there so I chose not to mention them.

This XML parsing library however is different.

This library aims to provide a different kind of  XML experience by placing emphasis on the libraries usage syntax rather than just peformance. This is done by making extensive use of blocks,  and providing an  easy to maintain and highly readable syntax.

The library is RaptureXML from Rapture In Venice.

You can find the the library on the Github page here:
https://github.com/ZaBlanc/RaptureXML

Be sure to check out the Github to see further details on what makes this library different and examples showing how readable and simple the usage code actually is.

©2011 iPhone, iOS 4, iPad SDK Development Tutorial and Programming Tips. All Rights Reserved.

.

DeliciousTwitterTechnoratiFacebookLinkedInEmail


Example: Create A Lightning Effect In Cocos2D Using OpenGL ES

Lightning is one of those effects that is greatly sought after in 2D games, you can use it to set up a spooky scene, have a bolt of lightning shoot a player character, blow up a section of bricks or pretty much anything you can come up with.

I’ve come across a class that allows you to easily add a dynamic lightning effect to your Cocos2D games.  This is done by directly drawing on the OpenGL ES scene so you could take this code, and easily modify it to work in any app that draws to the screen using OpenGL ES.

Here’s a demo of the class in action:

This version of the lightning class is from SupersuRacoon and can be downloaded through this post here: Simple Lightning Effect Demo.  This version of the class allows you to set all strike points for the lightning effect.

This was originally discussed on the Cocos2D forums here and you can find the original class from Mobile Bros on their website here.

A very nice lightning effect.

©2011 iPhone, iOS 4, iPad SDK Development Tutorial and Programming Tips. All Rights Reserved.

.

DeliciousTwitterTechnoratiFacebookLinkedInEmail


Tutorial: How To Extend UIControl And Build Your Own Custom Range Slider Component

You’ve probable seen situations in other apps, or perhaps even in your own where two sliders were used to configure the minimum and maximum parameters of a setting.

If you have then you have probably thought it would be great if there was a control with two scrubbers providing minimum/maximum settings.

I’ve come across an excellent tutorial showing step by step how to build a control that looks like it would fit right in with any other native controls.

What I like about this tutorial is that the author covers every step showing how he extended UIControl in building his custom component, and ultimately providing the source code for us to look at.

The tutorial is by Mal Curtis, and you can find it in two parts here:
iOS Range Slider Part 1
iOS Range Slider Part 2

The source can be found on Github here:
https://github.com/buildmobile/iosrangeslider 

A great guide if you would like to learn how to build your own drop-in custom iOS component.

©2011 iPhone, iOS 4, iPad SDK Development Tutorial and Programming Tips. All Rights Reserved.

.

DeliciousTwitterTechnoratiFacebookLinkedInEmail


Tutorials: Core Animation iOS Game Development Gems

In the past I’ve stated how Core Animation is a great for certain types of 2D games, and shared resources such as the geek game board for iOS.

That being said there are certain small, but annoying issues that can rise up in particular related to timing, and performance.

I’ve come across an excellent set of tutorials presenting some excellent gems for core animation game development. Presenting pare ractical solutions for many problems such as loading in texture atlases, handling animation timing, and creating complex backgrounds.

Part 1 – Frame By Frame Sprites With Core Animation
Part 2 – Space Time
Part 3 – Scrolling Hell
Part 4 – Parallax Scrolling

A great set of tutorials with some excellent sample code to learn from.

©2011 iPhone, iOS 4, iPad SDK Development Tutorial and Programming Tips. All Rights Reserved.

.

DeliciousTwitterTechnoratiFacebookLinkedInEmail


PhotoCapture Application in iPhone

In this application we will see how to capture photo of the view in the application by using button pressed and save the photo in the Photo gallery. So let see how it will worked.

Step 1: Open the Xcode, Create a new project using View Base application. Give the application “PhotoCapture”.

Step 2: Xcode automatically creates the directory structure and adds essential frameworks to it. You can explore the
directory structure to check out the content of the directory.

Step 3: Expand classes and notice Interface Builder created the RootViewController class for you. Expand Resources and
notice the template generated a separate nib, PhotoCaptureViewController.xib for the PhotoCaptureViewController class.

Step 4: Open the PhotoCaptureViewController.h file and make the following changes:

#import <UIKit/UIKit.h>
@interface PhotoCaptureViewController : UIViewController {
}
–(IBAction)captureScreen:(id)sender;
@end

Step 5: Double click the PhotoCaptureViewController.xib file and open it to the Interface Builder. First drag the label from the library andplace it to the view window. Select the label from the view and bring up Attribute Inspector and change the Text into “Welcome To iPhone” . Now save the .xib file, close it and go back to the Xcode.

Step 6: In the PhotoCaptureViewController.m file make the following changes:

#import "PhotoCaptureViewController.h"
@implementation PhotoCaptureViewController
–(IBAction)captureScreen:(id)sender
{
UIGraphicsBeginImageContext(self.view.frame.size);
[self.view.layer renderInContext:UIGraphicsGetCurrentContext()];
UIImage *viewImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
UIImageWriteToSavedPhotosAlbum(viewImage, nil, nil, nil);
}
– (void)dealloc
{
[super dealloc];
}
– (void)didReceiveMemoryWarning
{
// Releases the view if it doesn’t have a superview.
[super didReceiveMemoryWarning];
// Release any cached data, images, etc that aren’t in use.
}
– (void)viewDidUnload
{
[super viewDidUnload];
}
– (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}
@end

Step 7: Now compile and run the application in the Simulator and check Save image in the Photo Gallery.

You can Download SourceCode from here PhotoCapture.

How to show Login Screen On launch

In this application we will see how to display login screen only first lunch after downloading the application in iPhone. So let see how it will worked.

Step 1: Open the Xcode, Create a new project using Window Base application. Give the application “TabBarWithLogin”.

Step 2: Xcode automatically creates the directory structure and adds essential frameworks to it. You can explore the directory structure to check out the content of the directory.
Step 3: Expand Resources and notice the template generated a separate nib, MainWindow.xib for the TabBarWithLogin application.

Step 4: We need to add one UIViewController class in the application. So select NewFile -> UIViewController subclass. And give the class name “MainView”.
Step 5: Open the TabBarWithLoginViewcontroller.h file and make the following changes.

#import <UIKit/UIKit.h>
@class MainView;
@interface TabBarWithLoginAppDelegate : NSObject <UIApplicationDelegate,UITextFieldDelegate> {
IBOutlet UITextField *nameInput;
IBOutlet UITextField *passInput;
IBOutlet UILabel *greeting;
NSMutableData *webData;
MainView *mainView;
UIView *view;
}
@property (nonatomic, retain) IBOutlet UIWindow *window;
@property (nonatomic, retain) IBOutlet UIView *view;
@property (nonatomic) bool showUsageAlert;
@property(nonatomic, retain) IBOutlet UITextField *nameInput;
@property(nonatomic, retain) IBOutlet UITextField *passInput;
@property(nonatomic, retain) IBOutlet UILabel *greeting;
@property(nonatomic, retain) NSMutableData *webData;
@end

Step 6: In the TabBarWithLoginViewcontroller.m file make the following changes:

#import "TabBarWithLoginAppDelegate.h"
#import "MainView.h"
@implementation TabBarWithLoginAppDelegate
@synthesize window=_window ,showUsageAlert,nameInput,passInput,greeting,webData,view;
– (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
BOOL ranBefore = [defaults boolForKey: @"ranBefore"];
[defaults setBool: YES forKey:@"ranBefore"];
[defaults synchronize]; // save to disk
if (ranBefore){
NSArray *documentPaths =
NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,
NSUserDomainMask, YES);
NSString *documentsDir = [documentPaths objectAtIndex:0];
mainView = [[MainView alloc]
initWithNibName:@"MainView"
bundle:nil];
[view removeFromSuperview];
[self.window addSubview:mainView.view];
[mainView displayScreen];
}
else{
if(showUsageAlert = YES){
[self performSelector:@selector(showUsageAlertDialog) withObject:nil afterDelay:0.0];
}
}
}
– (void)showUsageAlertDialog
{
if (showUsageAlert=YES) {
view = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 320, 480)];
[self.window addSubview:view];
UILabel *myLabel2 = [[UILabel alloc] initWithFrame:CGRectMake(10, 30, 100, 100)];
myLabel2.text = @"User Name";
UILabel *myLabel1 = [[UILabel alloc] initWithFrame:CGRectMake(10, 100, 100, 100)];
myLabel1.text = @"Password";
myLabel1.backgroundColor = [UIColor clearColor];
[view addSubview:myLabel2];
[view addSubview:myLabel1];
nameInput = [[UITextField alloc] initWithFrame:CGRectMake(100, 70, 150, 31)];
nameInput.borderStyle = UITextBorderStyleRoundedRect;
nameInput.textColor = [UIColor blackColor];
nameInput.font = [UIFont systemFontOfSize:17.0];
nameInput.placeholder = @"Enter User name"; //place holder
nameInput.backgroundColor = [UIColor clearColor];
nameInput.autocorrectionType = UITextAutocorrectionTypeNo;
nameInput.backgroundColor = [UIColor clearColor];
nameInput.keyboardType = UIKeyboardTypeDefault;
nameInput.returnKeyType = UIReturnKeyDone;
nameInput.clearButtonMode = UITextFieldViewModeWhileEditing;
[view addSubview:nameInput];
nameInput.delegate = self;
passInput = [[UITextField alloc] initWithFrame:CGRectMake(100, 130, 150, 31)];
passInput.borderStyle = UITextBorderStyleRoundedRect;
passInput.textColor = [UIColor blackColor];
passInput.font = [UIFont systemFontOfSize:17.0];
passInput.placeholder = @"Enter Password"; //place holder
passInput.backgroundColor = [UIColor clearColor];
passInput.autocorrectionType = UITextAutocorrectionTypeNo;
passInput.backgroundColor = [UIColor clearColor];
passInput.keyboardType = UIKeyboardTypeDefault;
passInput.returnKeyType = UIReturnKeyDone;
passInput.clearButtonMode = UITextFieldViewModeWhileEditing;
[view addSubview:passInput];
passInput.delegate = self;
UIButton *button = [UIButton buttonWithType:UIButtonTypeRoundedRect];
[button addTarget:self
action:@selector(buttonPressed:)
forControlEvents:UIControlEventTouchDown];
[button setTitle:@"Button" forState:UIControlStateNormal];
button.frame = CGRectMake(20, 200, 97, 37);
[view addSubview:button];
}
}
–(IBAction)buttonPressed:(id)sender
{
mainView = [[MainView alloc]
initWithNibName:@"MainView"
bundle:nil];
[view removeFromSuperview];
[self.window addSubview:mainView.view];
[mainView displayScreen];
}
– (void)applicationWillResignActive:(UIApplication *)application
{
}
– (void)applicationDidEnterBackground:(UIApplication *)application
{
}
– (void)applicationWillEnterForeground:(UIApplication *)application
{
}
– (void)applicationDidBecomeActive:(UIApplication *)application
{
}
– (void)applicationWillTerminate:(UIApplication *)application
{
}
– (void)dealloc
{
[_window release];
[super dealloc];
}
@end

Step 7: Open the MainView.h file and make the following changes:

#import <UIKit/UIKit.h>
@interface MainView : UIViewController {
UITabBarController *tabBarController;
}
@property (nonatomic, retain) IBOutlet UITabBarController *tabBarController;
–(void)displayScreen;
@end

Step 8: Double click the MainView.xib file and open it to the view window. Drag the TabBar Controller from the library and place it to the Interface Builder. Connect File’s owner icon to the TabBar Controller and tabBarController. Now save the .sib file, close it and go back to the Xcode.

Step 9: Open the MainView.m and make the following changes:

#import "MainView.h"
@implementation MainView
@synthesize tabBarController;
–(void)displayScreen
{
[self.view addSubview:tabBarController.view];
}
– (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self) {
// Custom initialization
}
return self;
}
– (void)dealloc
{
[super dealloc];
}
– (void)didReceiveMemoryWarning
{
// Releases the view if it doesn’t have a superview.
[super didReceiveMemoryWarning];
// Release any cached data, images, etc that aren’t in use.
}
#pragma mark – View lifecycle
– (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view from its nib.
}
– (void)viewDidUnload
{
[super viewDidUnload];
// Release any retained subviews of the main view.
// e.g. self.myOutlet = nil;
}
– (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}
@end

Step 10: Now Compile and run the Application on the Simulator.

You can Download SourceCode from here TabBarWithLogin

PhotoCapture Application in iPhone

In this application we will see how to capture photo of the view in the application by using button pressed and save the photo in the Photo gallery. So let see how it will worked.

Step 1: Open the Xcode, Create a new project using View Base application. Give the application “PhotoCapture”.

Step 2: Xcode automatically creates the directory structure and adds essential frameworks to it. You can explore the
directory structure to check out the content of the directory.

Step 3: Expand classes and notice Interface Builder created the RootViewController class for you. Expand Resources and
notice the template generated a separate nib, PhotoCaptureViewController.xib for the PhotoCaptureViewController class.

Step 4: Open the PhotoCaptureViewController.h file and make the following changes:

#import <UIKit/UIKit.h>
@interface PhotoCaptureViewController : UIViewController {
}
–(IBAction)captureScreen:(id)sender;
@end

Step 5: Double click the PhotoCaptureViewController.xib file and open it to the Interface Builder. First drag the label from the library andplace it to the view window. Select the label from the view and bring up Attribute Inspector and change the Text into “Welcome To iPhone” . Now save the .xib file, close it and go back to the Xcode.

Step 6: In the PhotoCaptureViewController.m file make the following changes:

#import "PhotoCaptureViewController.h"
@implementation PhotoCaptureViewController
–(IBAction)captureScreen:(id)sender
{
UIGraphicsBeginImageContext(self.view.frame.size);
[self.view.layer renderInContext:UIGraphicsGetCurrentContext()];
UIImage *viewImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
UIImageWriteToSavedPhotosAlbum(viewImage, nil, nil, nil);
}
– (void)dealloc
{
[super dealloc];
}
– (void)didReceiveMemoryWarning
{
// Releases the view if it doesn’t have a superview.
[super didReceiveMemoryWarning];
// Release any cached data, images, etc that aren’t in use.
}
– (void)viewDidUnload
{
[super viewDidUnload];
}
– (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}
@end

Step 7: Now compile and run the application in the Simulator and check Save image in the Photo Gallery.

You can Download SourceCode from here PhotoCapture.

How to show Login Screen On launch

In this application we will see how to display login screen only first lunch after downloading the application in iPhone. So let see how it will worked.

Step 1: Open the Xcode, Create a new project using Window Base application. Give the application “TabBarWithLogin”.

Step 2: Xcode automatically creates the directory structure and adds essential frameworks to it. You can explore the directory structure to check out the content of the directory.
Step 3: Expand Resources and notice the template generated a separate nib, MainWindow.xib for the TabBarWithLogin application.

Step 4: We need to add one UIViewController class in the application. So select NewFile -> UIViewController subclass. And give the class name “MainView”.
Step 5: Open the TabBarWithLoginViewcontroller.h file and make the following changes.

#import <UIKit/UIKit.h>
@class MainView;
@interface TabBarWithLoginAppDelegate : NSObject <UIApplicationDelegate,UITextFieldDelegate> {
IBOutlet UITextField *nameInput;
IBOutlet UITextField *passInput;
IBOutlet UILabel *greeting;
NSMutableData *webData;
MainView *mainView;
UIView *view;
}
@property (nonatomic, retain) IBOutlet UIWindow *window;
@property (nonatomic, retain) IBOutlet UIView *view;
@property (nonatomic) bool showUsageAlert;
@property(nonatomic, retain) IBOutlet UITextField *nameInput;
@property(nonatomic, retain) IBOutlet UITextField *passInput;
@property(nonatomic, retain) IBOutlet UILabel *greeting;
@property(nonatomic, retain) NSMutableData *webData;
@end

Step 6: In the TabBarWithLoginViewcontroller.m file make the following changes:

#import "TabBarWithLoginAppDelegate.h"
#import "MainView.h"
@implementation TabBarWithLoginAppDelegate
@synthesize window=_window ,showUsageAlert,nameInput,passInput,greeting,webData,view;
– (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
BOOL ranBefore = [defaults boolForKey: @"ranBefore"];
[defaults setBool: YES forKey:@"ranBefore"];
[defaults synchronize]; // save to disk
if (ranBefore){
NSArray *documentPaths =
NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,
NSUserDomainMask, YES);
NSString *documentsDir = [documentPaths objectAtIndex:0];
mainView = [[MainView alloc]
initWithNibName:@"MainView"
bundle:nil];
[view removeFromSuperview];
[self.window addSubview:mainView.view];
[mainView displayScreen];
}
else{
if(showUsageAlert = YES){
[self performSelector:@selector(showUsageAlertDialog) withObject:nil afterDelay:0.0];
}
}
}
– (void)showUsageAlertDialog
{
if (showUsageAlert=YES) {
view = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 320, 480)];
[self.window addSubview:view];
UILabel *myLabel2 = [[UILabel alloc] initWithFrame:CGRectMake(10, 30, 100, 100)];
myLabel2.text = @"User Name";
UILabel *myLabel1 = [[UILabel alloc] initWithFrame:CGRectMake(10, 100, 100, 100)];
myLabel1.text = @"Password";
myLabel1.backgroundColor = [UIColor clearColor];
[view addSubview:myLabel2];
[view addSubview:myLabel1];
nameInput = [[UITextField alloc] initWithFrame:CGRectMake(100, 70, 150, 31)];
nameInput.borderStyle = UITextBorderStyleRoundedRect;
nameInput.textColor = [UIColor blackColor];
nameInput.font = [UIFont systemFontOfSize:17.0];
nameInput.placeholder = @"Enter User name"; //place holder
nameInput.backgroundColor = [UIColor clearColor];
nameInput.autocorrectionType = UITextAutocorrectionTypeNo;
nameInput.backgroundColor = [UIColor clearColor];
nameInput.keyboardType = UIKeyboardTypeDefault;
nameInput.returnKeyType = UIReturnKeyDone;
nameInput.clearButtonMode = UITextFieldViewModeWhileEditing;
[view addSubview:nameInput];
nameInput.delegate = self;
passInput = [[UITextField alloc] initWithFrame:CGRectMake(100, 130, 150, 31)];
passInput.borderStyle = UITextBorderStyleRoundedRect;
passInput.textColor = [UIColor blackColor];
passInput.font = [UIFont systemFontOfSize:17.0];
passInput.placeholder = @"Enter Password"; //place holder
passInput.backgroundColor = [UIColor clearColor];
passInput.autocorrectionType = UITextAutocorrectionTypeNo;
passInput.backgroundColor = [UIColor clearColor];
passInput.keyboardType = UIKeyboardTypeDefault;
passInput.returnKeyType = UIReturnKeyDone;
passInput.clearButtonMode = UITextFieldViewModeWhileEditing;
[view addSubview:passInput];
passInput.delegate = self;
UIButton *button = [UIButton buttonWithType:UIButtonTypeRoundedRect];
[button addTarget:self
action:@selector(buttonPressed:)
forControlEvents:UIControlEventTouchDown];
[button setTitle:@"Button" forState:UIControlStateNormal];
button.frame = CGRectMake(20, 200, 97, 37);
[view addSubview:button];
}
}
–(IBAction)buttonPressed:(id)sender
{
mainView = [[MainView alloc]
initWithNibName:@"MainView"
bundle:nil];
[view removeFromSuperview];
[self.window addSubview:mainView.view];
[mainView displayScreen];
}
– (void)applicationWillResignActive:(UIApplication *)application
{
}
– (void)applicationDidEnterBackground:(UIApplication *)application
{
}
– (void)applicationWillEnterForeground:(UIApplication *)application
{
}
– (void)applicationDidBecomeActive:(UIApplication *)application
{
}
– (void)applicationWillTerminate:(UIApplication *)application
{
}
– (void)dealloc
{
[_window release];
[super dealloc];
}
@end

Step 7: Open the MainView.h file and make the following changes:

#import <UIKit/UIKit.h>
@interface MainView : UIViewController {
UITabBarController *tabBarController;
}
@property (nonatomic, retain) IBOutlet UITabBarController *tabBarController;
–(void)displayScreen;
@end

Step 8: Double click the MainView.xib file and open it to the view window. Drag the TabBar Controller from the library and place it to the Interface Builder. Connect File’s owner icon to the TabBar Controller and tabBarController. Now save the .sib file, close it and go back to the Xcode.

Step 9: Open the MainView.m and make the following changes:

#import "MainView.h"
@implementation MainView
@synthesize tabBarController;
–(void)displayScreen
{
[self.view addSubview:tabBarController.view];
}
– (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self) {
// Custom initialization
}
return self;
}
– (void)dealloc
{
[super dealloc];
}
– (void)didReceiveMemoryWarning
{
// Releases the view if it doesn’t have a superview.
[super didReceiveMemoryWarning];
// Release any cached data, images, etc that aren’t in use.
}
#pragma mark – View lifecycle
– (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view from its nib.
}
– (void)viewDidUnload
{
[super viewDidUnload];
// Release any retained subviews of the main view.
// e.g. self.myOutlet = nil;
}
– (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}
@end

Step 10: Now Compile and run the Application on the Simulator.

You can Download SourceCode from here TabBarWithLogin

Quora iPhone app puts answers to every question at your fingertips

Quora, the popular Q&A social networking site, has released their first iPhone app. Quora for iPhone allows users to ask and answer questions on the go. The iPhone app has kept the core of what makes Quora popular and easy to use, plus it has added some unique features.

The iPhone app offers a new feature called “Nearby.” It’s essentially location-based questions. You can browse questions based on areas from an embedded Google Map within the app. Nearby hones in on your current location, but if you want you can jump to another city our country and see specific questions for any area in the world.

Another welcome addition to the iPhone app: Push notifications, so when you ask a question you don’t need to sit around and constantly check the app to see if it’s been answered. Quora has also integrated its Shuffle feature into the iPhone app, allowing you to discover new content you might not normally seek out.

Quora for iPhone is available now in the App Store. It’s a free download.

Quora iPhone app puts answers to every question at your fingertips originally appeared on TUAW – The Unofficial Apple Weblog on Thu, 29 Sep 2011 15:00:00 EST. Please see our terms for use of feeds.

Source | Permalink | Email this | Comments

Apple tells education customers: no more boxed software

It seems Apple is about to cease (almost) all shipments of boxed software to its education customers. ZDNet has published an email that was sent to “a major academic institution” (ZDNet does not mention who wrote or distributed the email, but it sounds like it could have come from a member of the school’s faculty or staff). From the message:

“Apple confirmed today that, with limited exception, they will cease to ship boxed software to campus resellers. This includes Mac OS X Snow Leopard , iLife, iWork, Apple Remote Desktop, and Aperture, among others…The only products that will remain as boxed software offerings are Logic Express and Logic Studio.

The email’s author goes on to encourage interested parties to sort through the remaining stock of boxed software for anything they might need.

Apple opened the Mac App Store in January of this year, which saw the beginning of the end for boxed software for consumers on the Mac. Now that Apple set to sever the supply of boxed software for educational institutions, it moves even closer to all-digital distribution.

The exceptions, as noted in the email, are Logic Express and Logic Studio. However, that is presumably only because those two software apps aren’t available on the Mac App store yet. When they are, boxed software from Apple will see its final day.

Apple tells education customers: no more boxed software originally appeared on TUAW – The Unofficial Apple Weblog on Thu, 29 Sep 2011 14:30:00 EST. Please see our terms for use of feeds.

Source | Permalink | Email this | Comments

Rumor: iPhone 5 supports HSPA+ ‘4G’

Less than one week before Apple’s announcement of a new iPhone or two, Japanese blog Macotakara has published a photo of a slide shown by China Unicom during a presentation at Macworld Asia. What’s on the slide? Notes about an ‘iPhone 5’ to be delivered in 2011 that supports the HSPA+ ‘4G’ mobile network standard.

HSPA+ is not true 4G — LTE (3GPP Long Term Evolution) is. In the USA, AT&T advertises their HSPA+ network as 4G, noting that they’re upgrading the system to “true” 4G LTE. The company just turned on LTE 4G in five US cities this month; Chicago, Atlanta, Dallas-Ft.Worth, Houston, and San Antonio. However, the HSPA+ network covers most American large population centers, providing maximum theoretical data speeds of up to 21 Mbps. That’s about three times the theoretical max speed for the current HSPA 3G network.

Verizon does not have an interim network, but supports ‘true’ LTE 4G, so an HSPA+ iPhone would not work on their network. T-Mobile USA, which does not currently carry the iPhone, has an upgraded HSPA+ network that supports maximum data speeds up to 42 Mbps and coverage in 25 US cities. Sprint, the company expected to be the next iPhone carrier, is moving directly to LTE 4G through a deal with the controversial LightSquared.

The photo (a portion of which is shown above) was taken by a blogger for Japanese website PC Watch, and shows the evolution of the iPhone on the China Unicom network over the years.

Rumor: iPhone 5 supports HSPA+ ‘4G’ originally appeared on TUAW – The Unofficial Apple Weblog on Thu, 29 Sep 2011 14:15:00 EST. Please see our terms for use of feeds.

Source | Permalink | Email this | Comments