My delegate for ended animations looks like this:
(void)animationDidEnd:(NSString *)animationID finished:(BOOL)finished context:(void *)context
for some reason, the finished is always NO in my animation chain. But I need to know if an animation in my chain has finished completely.
Example: Something says: "move to (20,100)". And as ...
I've a iPhone App that relies heavily of TableViews and SQLite database. Where do you store the data? In my case I pull data from the web in App Delegate and store it in AppDelegate and save it to DB at regular intervals.
The rootviewcontroller is a tableview that reads the appdelegate object and populates itself.
But, according to Eva...
I want to change the background color of my UIAlertView, but this doesn't appear to have a color attribute.
...
UiWebView redirect its self to already login page.i want to stop redirect?
I want web view to reload login page and ask for username and password.Clear context and load request again.
NSString *urlAddress = [NSString stringWithFormat:@"http://www.facebook.com/login.php?];
//Create a URL object.
NSURL *urld = [NSURL URLWithString...
I think I've found the cause: Document Info window in IB has a warning: "'Selected Navigation Controller (Second)' has nib name property set to 'SecondView.nib', but this view controller is not intended to have its view set in this manner."
Bummer.
I've built nib in Interface Builder that has UITabBarController at top level and switc...
I've modified the ViewTransitions app to use kCAScrollHorizontally. I've set transition in the app delegate to use kCATransitionPush rather than kCATransitionFade. However, I still get fading in and out. How can I get the views to slide in landscape just like the Star Trek app (http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoft...
More often than I'd have hoped I seem to come across method/property definitions in Apple's documentation that are vague at best and meaningless, to me, at worst. For example, take the following method description from NSNumberFormatter Class Reference:
setPartialStringValidationEnabled:
Sets whether partial string validation
...
I would like to change the first character of an NSString to uppercase. Unfortunately, - (NSString *)capitalizedString converts the first letter of every word to uppercase. Is there an easy way to convert just a single character to uppercase?
I'm currently using:
NSRange firstCharRange = NSMakeRange(0,1);
NSString* firstCharacter = [da...
I am trying (from my 3rd child in the heirachy) to load the root view with the following. This does not work and I get the following error when the below code is run.
-[DetailViewController clickButton:]: unrecognized selector sent to instance 0x1161e00'
Code:
MapViewController *dvController = [[MapViewController alloc] initWithNib...
I have a button in my iPhone app that I'd like to have play the default "keyboard tap" sound when it's tapped. I've been able to play my own custom sounds easily enough, but is there any way to play a default system sound like this in my app?
...
Hey everyone,
I'm having difficulty scrolling a UIScrollView instance in my UITableView when I set it as a tableHeaderView.
It still responds to touch events it appears, but doesn't wish to scroll horizontally. I've tried explicitly setting to setUserInteractionEnabled:YES without much luck.
Is there something in particular I need to...
Hi
I am working on a subclass of UIImageView and one of the things I require is when the object is initalised with the initWithImage: message a 'copy' is created.
I must be confusing something because I can't see what is not working here..
- (id)initWithImage:(UIImage *)image {
[image retain];
if (self = [super initWithImage:image]) {...
I like to replicate the form behavior of Safari on the iPhone in my own app. If you enter data in an web form you get a separate UIToolbar (previous, next, done) just above the UIKeyboardView. Same for choosing an option: you get the same UIToolbar just above an UIPickerView.
I am looking for demos / sourcode / ideas how to implement th...
Hello,
How can I set UIcolor to have a deepblue values (like 330099, shown in interface builder) programmatically?
Thanks.
...
Is it ok to add ivars and methods to an instance of NSMangaedObject?
By "extra", I mean ivars that you don't want serialized.
Do I just add them to my NSMangaedObject subclass like any other class or do I have to take any extra precautions?
...
I want to load a nib that isn't a view in a UITabViewController. Here's what I have now and it isn't working, but it should give you an idea of what I want:
- (IBAction)PlaylistButtonPressed:(id)sender
{
MusicPick *music = [[MusicPick alloc] initWithNibName:@"MusicPick" bundle:nil];
[self.view addSubview:music.view];
[mus...
I have an interval consisting of two float numbers, and need to generate 20 random numbers in a look that are somewhere inbetween this interval defined by the two floats.
Lets say, for example:
float a = 12.49953f
float b = 39.11234f
float r = //best way to get best randomly numbers between a and b
The random number may be == a and =...
I want to create a set of functions, that make life easier. I use them in about 60% of all project files. I wonder what's the most efficient way of including these in the project.
I think about creating one file where they go in and including this file in every file where I need them. On the other hand, it would be cool if I can include...
Hi,
I'm not sure why this is so hard. I have a UISearchBar at the top of my page. When the user types into that UISearchBar, it will automatically filter the results in the UITableView that is below the search bar. There is no need for a Search button since I search when keys are pressed.
The flow of the application is that the user ty...
Currently I am making some decisions for my first objective-c API. Nothing big, just a little help for myself to get things done faster in the future.
After reading a few hours about different patterns like making categories, singletons, and so on, I came accross something that I like because it seems easy to maintain for me. I'm making...