In iOS 5.0, Twitter was integrated, and in iOS 6.0, Facebook was integrated. Our lesson focuses on leveraging Apple's classes, with iOS 5.0 and iOS 6.0 as deployment targets for Twitter and other social networking platforms.
Let's have a look at how to do it:
Step 1: Make a straightforward view-based application
Step 2: Choose your project file, then targets, and finally frameworks, then add Social.framework and Accounts.framework
Step 3: Create ibActions for a button named twitterPost
Step 4: ViewController.h should be updated as follows:
Step 5: ViewController.m should be updated as follows:
Output
You receive the following output when you click twitterPost: