-(void) readProductsFromDatabase {
// Setup the database object
sqlite3 *database;
// Init the animals Array
products = [[NSMutableArray alloc] init];
// Open the database from the users filessytem
if(sqlite3_open([databasePath UTF8String], &database) == SQLITE_OK) {
NSLog(@"db opened");
// Setup the SQL Statement and c...
Hello,
I'm working with the ID3 framework in Xcode (which has since disappeared off the face of the web - including google cache!).
I'm testing out an import mp3 feature which allows them to edit the tags as they import them. One of the test cases is a corrupt or invalid mp3 with no proper id3 header. The problem I'm having is that whe...
Simply, I have placed an image with the Interface Builder in a UIView. Now I want to run a method/function when I am touching that image, for example when another image should be loaded.
My Code:
- (void)touchesended:(NSSet*) touches withEvent:(UIEvent *)event {
// UITouch *touch = [touch anyObject];
bild_1_1.image = [UIImage...
I have a method that is called addHighScore. When a user wants to quit the game, they can save their score out. In the resources folder, I created a highScore.plist and populated it with one entry. The structure is:
item 1 (array)
Name (dictionary, string)
Level (dictionary, string)
Score(dictionary, Number)
My...
I have an Xcode project that contains many sub-projects. The main project file and all sub-projects have the same xcconfig file. Some of the sub-projects currently have a build rule set on them to use the Intel compiler for C++ files. I'm wondering if there is a way to move this build rule into the xcconfig file so that I can easily turn...
How/where in the code does the nib file get related to its *.m and *.h files?
Specifically I'm talking about when you create a new Objective-C class, not using the initWithNibName method.
Wherever this relationship is defined is obviously used by the 'Files Owner' relationship in Interface Builder. I imagine it's a *.plist file somewh...
I just started getting this error today, seemingly out of nowhere. Any one see this before and know what causes it.
Internal error occurred while creating dependency graph: *** -[NSCFArray initWithObjects:count:]: attempt to insert nil object at objects[10]
This happens when I try to build with "iPhone Device 3.x" selected. However, i...
I have a NSTextField within a Window and I created a very simple MacRuby delegate:
class ServerInputDelegate
attr_accessor :parent
def textDidChange(notification)
NSLog notification.inspect
parent.filter
end
end
And I have tried setting the control's delegate:
I have tried setting the Window and every o...
I use AVAudioPlayer to play an mp3 file to a user within my iPhone app. This all works fine and dandy. I even update a PLAY/PAUSED button depending on the state of the player. But it would be nice to know how much longer the song will play.
So How do I show the time remaining?
...
Hi , when i want compile my app with the Distribution or Release method i get 140 ERRORS, i am using facebook connect on my app , and the path is right [my errors refer to fbconnect] , xcode runs my app fine on the debug !!!!!!! what's the problem ?
...
I am trying to use the IB AdMob ad in my app. I followed the instructions provided but I am getting an EXC_BAD_ACCESS from the AdMob class. I am trying to figure out what the problem is.
Anyway, my question is Can a ViewController (AdMob AdViewController) control a view that is a subview of the controlled view of another UIViewControll...
Hi All,
In eclipse when you click on a method name a variable, or an object for example, the same ones are highlited in a specific color elsewhere in the code for easy finding.
Is there a similar feature in Xcode?
...
Here is the code I have to create an UIalertView with a textbox.
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Enter A Username Here" message:@"this gets covered!"
delegate:self cancelButtonTitle:@"Dismiss" otherButtonTitles:@"OK!", nil];
UITextField *myTextFie...
My code looks like this:
NSIndexPath *ip = [NSIndexPath indexPathForRow:15 inSection:0];
[[self tableView] selectRowAtIndexPath:ip animated:YES scrollPosition:UITableViewScrollPositionMiddle];
// Pause needed here until animation finishes
[[self navigationController] pushViewController:secondView animated:YES];
Right now it animates...
First, I would to thank everyone for all the help they provide via this website. It has gotten me to the point of almost being able to release my first iPhone app!
Okay, so the last part I have is this: I have a game that allows users to save their high scores. I update a plist file which contains the users Name, Level, and score.
...
I keep getting 'warning: control reaches end of non-void function' with this code:
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
if (section ==0)
{
return [comparativeList count];
}
if (section==1)
{
return [generalList count];
}
if (section==2)
{
return [contactList count...
I went through the dev portal provisioning process twice now trying to get it to work, but to no avail. I don't think it's the second half (signature is invalid), I think it actually may have to with my binary. I have a warning in xcode that isn't helping me because I don't know what to do about it. And honestly I don't know how relev...
When I select a cell in section 0 of my tableview I always get taken to section 1 first ?
I think its somthing to do with my 'if' statments
code : http://pastie.org/868523
Thanks in advance.
...
I have an iPhone app. that is receiving data with IRFC 3339 timestamp format (e.g. @"2010-01-29T11:30:00.000+01:00"), as in GData. I want to convert the data to an NSDate
NSDateFormatter *inputFormatter = [[[NSDateFormatter alloc] init] autorelease];
[inputFormatter setDateFormat:@"yyyy-MM-dd'T'HH:mm:ss.SSS"];
[currentEntry setStartTime...
FBStreamDialog* dialog = [[[FBStreamDialog alloc] init] autorelease];
dialog.delegate = self;
dialog.userMessagePrompt = @"Example prompt";
dialog.attachment = @"{\"name\":\"Facebook Connect for iPhone\","
"\"href\":\"http://developers.facebook.com/connect.php?tab=iphone\","
"\"caption\":\"Caption\",\"descript...