I am trying to do something I thought would be simple.
I have a form with two UITextFields on it. I am using the UIReturnKeyNext style on the first. The idea is that when the user fills in the first field, they click Next and I transition them to the next UITextField. I've seen other apps that do this and it works really well. But I can...
I have a situation where I build a view with a table and another view for table header (containing images and labels and buttons). Now I connected the table, image, labels, buttons to variables in my Controller class. Should I release the memory in -dealloc method for all those variables that I connected using Interface Builder? I believ...
Any ideas on how to get the functionality of an attributed string on an iPhone.
Specifically, I am writing out chemical compounds and want to properly display subscripts: for example:
H2O (the 2 should be a subscript)
Thanks for any suggestions
...
I am using a tableview and when the user selects a row, I am playing the video associated with the row using an MPMoviePlayerController object. Now as soon as the playback finishes, MPMoviePlayerController is released and control goes back to the previous controller.
How can I prevent this from happening? I want to take the user back to...
Here's my case: I have a table view showing contacts. Add button in the navigation bar is used to load another view for data entry. This new view has images in table header, and each table cell has either a UITextField or a UITextView. When i press Cancel, the view is popped out and memory is released.
Here's my issue: When i open the ...
I am trying to connect to a remote mysql database from an iPhone. I have searched many web sites but I did not find any help. If anyone has worked with this please send a solution.
...
Question is should i use properties for my view controllers?
Consider the following case:
I have a view controller object in my parent class: MyViewController *myVC;
I don't release this view controller in parent class's dealloc method.
I use view controller like this:
// Allocate and Initialize view controller
myVC = [[MyViewControl...
I'm doing a series of translations and rotations on the CTM and at some point I need to reset it to identity before going further with transformations.
I can't find any proper way to do it (obviously, there should have been a function named CGContextSetCTM or so) and since efficiency is the key, I don't want to use CGContextSaveGState/C...
I am trying to capture the contents of a UIWebView including that which is not visible to the user. i.e. The whole web page even though the user is only looking at the top.
Looking around I found the best way to capture a UIView is to retrieve its layer and use renderInContext.
However, UIWebView seems to be using its own CALayer imple...
I am building an application which allows the user to view and edit data on a daily basis. To accomplish this i have created a view in Interface builder which contains all of the daily data, and i "tile" this view within an appropriately sized UIScrollView to allow the user to swipe between the days. The view contains two UITextFields,...
I've found the following code for parsing through RSS but it does not seem to allow for nested elements:
- (void)parser:(NSXMLParser *)parser didEndElement:(NSString *)elementName namespaceURI:(NSString *)namespaceURI qualifiedName:(NSString *)qName{
NSLog(@"ended element: %@", elementName);
if ([elementName isEqualToString...
I'd like to save an NSMutableDictionary object in NSUserDefaults. The key type in NSMutableDictionary is NSString, the value type is NSArray, which contains a list of object which implements NSCoding. Per document, NSString and NSArray both are conform to NSCoding.
I am getting error :
-[NSUserDefaults setObject:forKey:]: Attempt to i...
I'm experiencing the same problem in this previous stackoverflow.com post.
Specifically, I seem to be able to get the "Auth" token correctly, but attempts to use it in the header when I access later pages still just return me the login page's HTML.
Following links related to this post, I've determined that you need to make a subsequen...
I am building an app, which has TabBarController, and each tab view has navigation view controller. When user click tab, I'd like the relavent navigation view controller to "reset" to the root panel.
In my code, I uses the following way to initialize the tab and navigation controller.
viewController1 = [[MyFirstController alloc] init];...
I know this is a common convention, but what does the "k" in variable names signify? (i.e. kMaxImageViewSize) I looked in the Apple documentation on Variable names and found no mention of it.
Thanks for answering
...
On the iPhone, when your phone is locked and screen off, if a SMS message comes in, the screen turns on and an alert shows up.
Currently I am using UIAlertView to create the alert dialog (with 2 buttons).
If the phone is off/locked, nothing shows up until I turn it back on and unlock it.
Is there any way to simulate the 'SMS preview' be...
Many classes in Cocoa/Cocoa Touch have the NS prefix. What does it mean?
Thanks
...
I'm looking to determine whether a string value from a user input (UITextField) is "blank" if it's not nil. Checking if [textField.text isEqualToString:""] isn't quite enough because I want to avoid any blank/whitespace input (like say a few space characters).
There does seem to be an indication of a good solution for my particular pro...
I wonder if I can test landscape view using simulator?
...
Are there any reasons why the simulator will display UIImageViews properly, but incorrectly on the iPhone?
My Process:
An image in a PNG file
Start a UIGraphicsBeginImageContext()
Draw the PNG in a CGrect
Draw text in the CGRect
Create an UIImage from the context
Set the image of a UIImaveView to the UIImage
Set the frame of the UIImag...