January 2012
Beginner
655 pages
16h 35m
English
In this chapter, you learned how you can easily integrate the various built-in applications into your own iPhone applications. In particular, you saw how you can invoke the built-in SMS, Mail, Safari, and Phone simply by using a URL string. In addition, you learned how to send SMS and e-mail messages without leaving your application. You also learned about accessing the Photo Library applications using the classes provided by the iPhone SDK.
EXERCISES
Answers to the exercises can be found in Appendix D.
WHAT YOU LEARNED IN THIS CHAPTER
| TOPIC | KEY CONCEPTS |
| Sending e-mail from within your application |
NSString *emailString = @“mailto:?to=user@email.com&subject=Subject&body=Body”; [[UIApplication sharedApplication] openURL:[NSURL URLWithString:emailString]]; |
| Invoking Safari |
[[UIApplication sharedApplication] openURL:[NSURL URLWithString: @“http://www.apple.com”]]; |
| Invoking the Phone |
[[UIApplication sharedApplication] openURL:[NSURL URLWithString: @“tel:12345678*2” ]]; |
| Invoking SMS |
[[UIApplication sharedApplication] openURL:[NSURL URLWithString: ... |