I'm getting this from an iPhone app I'm working on. Not sure how to interpret the error... It's thrown at a few place in my code. I can't see any pattern of occurrence.
Is this a generic error? What's the meaning of it?
...
-(void)viewWillAppear:(BOOL)animated
{
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(keyboardWillShow:) name:UIKeyboardWillShowNotification object:self.view.window];
[super viewWillAppear:animated];
}
-(void)viewWillDisappear:(BOOL)animated
{
[[NSNotificationCenter defaultCenter] removeObserver:...
Hi,
I am trying to get a string value out of a textField when the user dismisses the keyboard. However, it seems that whenever I try to get the value, I get garbage (attempting to print out textField.text gives out garbage). What could I be doing wrong?
(The control displays fine, and I can put text values into it even).
Here's my cod...
Hello,
I'm a Objective-C learner and I don't have a Mac, then I need to use my Linux with GNUStep, but if I develop my own program on it, the end-user will need to have GNUStep(like .Net) installed and then I started thinking how can I solve this, then I had an idea: "Create this from scratch!", but now to do this I need to know: What ar...
I am developing an iPhone application which requires a multiline text field (UITextView) to capture some text.
When the user touches inside the textView it becomes firstResponder and displays the keyboard. What I really need it to do is remove the keyboard when the user is finished. Normally with a text field the return/done button pres...
I have already found a lot of information about how to solve memory leaks for iPhone Obj C code. The last two leaks keep me puzzled, I'm probably overlooking something. Maybe you can spot it.
Instruments reports 2 leaks for the following code (part of a UIViewController subclass):
(1) UIWebView *webView = [[UIWebView alloc] initWithFr...
I have declared an NSMutableArray *categories in my view controller .h file, and declared a property for it.
In the parser:foundCharacters: method of the NSXMLParser delegate in my .m file, I have this code:
-(void)parser:(NSXMLParser *) parser foundCharacters:(NSString *)string
{
if (elementFound)
{
element = ...
Hy, I have a childe view that put it self over other brother views. The problem is that when i touch it the brother also reacts at the touch event. How can I disable touch propagation on the underlieng brother views?
...
So this is my first posting on StackOverflow, so excuse me if my request is not well formed.
I am attempting to load a variable with type NSString into an NSURL with the following line:
audioPlayer = [[AudioPlayer alloc] initPlayerWithURL:[NSURL URLWithString:aArchiveItem.streamURL] delegate:self];
And in AudioPlayer implementation I...
I'm working on writing a rather basic app. It uses minimal touch input, and mostly just plays fancy animations. There isn't much animation, but the way it's currently done seems super inefficient and uses far too much memory.
The view is split into two parts, the bottom 1/5th is just one image that doesn't ever change. The rest of it i...
This has been asked many times. But most answers are not applicable to the latest OS (3.0+) or they are "Apple will reject it".
What I need is to programmatically grab the image displayed in the preview of the UIImagePickerController without having the user take a photo and use the image - what I actually need is to get a screenshot of ...
The iPhone camera toolbar is gray and has a slight gradient. I believe I could achieve the same look by setting the tintColor and/or translucency of the toolbar.
Any idea how I could make my toolbar look exactly like the camera one?
This isn't quite right... too dark:
UIToolbar *tb = [[UIToolbar alloc] initWithFrame:frame];
tb.tint...
I am using a UIImagePickerController subclass to take photos in my app.
The toolbar for the camera has a cancel button and a photo button on it. I would also like to add another button on the right.
I have tried to add a UIBarButtonItem to the subclass's toolbar, but that doesn't work. I have also tried to make a UIToolbar that looks l...
Or even, is it posible to make the UIToolbar invisible?
How can I achieve the effect of showing a standard UIBarButtonItem, without showing a UIToolBar?
...
I would like to trigger the camera with a non-standard button.
What function do I call to trigger the camera?
...
Hello, I am wondering how to convert an NSArray example: ( [43,545,@"Test"] ) to a string in objective-c. An applescript example might be:
set the_array to {43,"Testing", 474343}
set the_array to the_array as string
...
Hello,
I am new with Objective C and iPhone development but that is what I am trying to do... Problem is with QuarzCore and basic animation stuff. These lines are from my applicationDelegate:
#import "QuartzCore/QuartzCore.h"
...
-(void)performTransition {
if(!transitioning) {
CATransition *transition = [CATransition anim...
Whenever I implement a method in my own code that can accept or return objects of more than one class, I always try to use the most specific superclass available. For example, if I were going to implement a method that might return an NSArray * or an NSDictionary * depending on its input, I would give that method a return type of NSObje...
Hello I am wondering if there is a way to animate a window in objective-c using core-animation or quartz. I would like to fade out a window when I close it. My OSX operating system is Tiger.
Edit: Is it possible to do the same with an applescript application in Xcode by somehow calling a method from objective-c or another way?
...
I want to run a simple command from my cocoa app through code, NOT creating a shell script and running it that way, but by running it through the application, being able to define everything and change it on the fly
...