iphone

load iPhone background app in the same state as the first time

In ios4, when you quit your iphone application with the homebutton, it goes to the background. the second time you enter your app (foreground) I wanna be able to load the app like the first time (ViewDidAppear) and not in the state that I left it. ...

Creating an array of custom objects in Objective C

EDIT What i am trying to achieve with the code, is to create an array of 20 unique 'Person' objects. I know now thanks to the guys below that i am going way off calling dealloc. for (int i = 0; i < 20; i++) { Person *myPerson = [[Person alloc] init]; myPerson.name = @"Brian"; myPerson.age = [NSNumber numberWithInteger:23]; ...

question about reading data from urls on iphone/ipad

I have an app which uses a UIWebView to load a webpage, I then parse the links (triggered by a call of webViewDidFinishLoad) from that webpage and load all these html files using NSString initWithContentsOfURL. This works, but it takes forever to load the links... even tho I've clocked how long each initWithContentsOfURL call takes and t...

Icon specified in the Info.plist CFBundleIconFile does not have an extension

when i want to send my app to itunesconnect from applicationloader occur below error how to solve it ? Icon specified in the Info.plist CFBundleIconFile does not have an extension ...

Is kAudioSessionCategory_AudioProcessing unavailable on the iPhone simulator?

I understand that some Audio Session capabilities are not available in the simulator. Is that why AudioSessionSetProperty is failing for me on the simulator when I try to set it to kAudioSessionCategory_AudioProcessing? Everthing works fine on the actual device. ...

Why am I receiving two alerts for the scheduled local notification?

I'm receiving two alerts for the notification below, and I cannot for the life of me figure out why. The code only appears to be called once, but App: didReceiveLocalNotification is being called twice. And I can't figure out why! NSLog(@"Configuring notifications time is up."); noTimeLeft=[[UILocalNotification alloc]init]; ...

A method to override that gets called a couple of times a second? or a loop its safe to code into?

Hi guys, Making a simple card game, and it it should ok when the user is in control since he will push a button. It will call my method assigned to that button and logic will be performed and screen updated. But when the players turn ends, and i want the AI to run everything for a few seconds, update the screen with its decisions etc. ...

I'm in an iPhone provisioning mess -- Insight needed

My app has been more or less ready to be submitted for a while now, but as usual, the overly complex provisioning nonsense that Apple forces developers to jump through is causing me an enormous amount of stress. Initially the problem I was receiving was Invalid Codesign. After trying every 'solution' i could find on the internet and fa...

How to subclass the NSObject while getting rid of -(id)init?

I want a class that take a REQUIRED argument like the UITableViewController that does not have init. Currently I just throw an exception when invoking init. Is there a way to deactivate it completely? ...

UIImagePickerController continue to select image

Hello everyone I know UIImagePickerController can only select one image from library each time. When user select one image, UIPickerController will disappear. But I noticed the app "Good Reader", when it launchs UIImagePickerController, after user choose one image, it prompt a small window says "processing the image", but UIImagePickerC...

How to implement a selection menu on the iPhone

How do I implement this menu in the iPhone SDK? http://www.simplemobilereview.com/wp-content/uploads/2010/03/iphone-way.jpg ...

Best Method For Playing M4A file in iPhone App

Greetings, I have a tableview where I have parsed an list of podcasts(m4a format). I want to now play the podcasts. I have seen Matt Gallaghers method but it seems a bit excessive for what I need. I remember seeing a tutorial where you could play such a file in UIWebview but it doesn't seems to work. Any suggestions would be greatly...

Objective C parse hex string to integer

I would like to know how to parse a hex string, representing a number, in objective c. I am willing to use both an objective, or a C based method, either is fine. example: #01FFFFAB should parse into the integer: 33554347 Any help would be appreciated! ...

What's the best way for a ViewController to communicate to his model?

I'm currently relying on the fact that UIApplication is a singleton and I access the models as delegate's properties, but that seems a long chain to me. Controller->UIApplication->delegate->Model (->particular property to be set) ...

trouble with saving iPhone App variables of different types

Hi to All! As all who usually ask such questions I'm newbie in iPhone SDK programming and I've spend realy a lot of time to find the solution by my self. So, I need to save a lot of app data of diff datatypes (bool,string,int,float,double,int arrays,double arrays and arrays of pointers) to file. There're many forms with fields, app sett...

ALAssetRepresentation fullResolutionImage's UIImageOrientation is wrong

Hi all, I'm trying to ALAssetLibrary to fetch pictures in Photos app, but recently I found a problem, when I get the CGImageRef from ALAssetRepresentation, the UIImageOrientation is wrong(rotated 90 degree), but when I get width and height from the CGImageRef, they're wrong either, now how could I get the right CGImageRef or use the CGIm...

Editing the iPhone Simulator hosts file

Hi, is it possible to edit the hosts file of the iPhone simulator? I'm working on a REST API and I need to be able to access my local site using a correct domain (e.g. http://api.local.com) ...

Are iPhone/iPod Touch screenshots in landscape mode displayed that way in the app store?

I recently uploaded some screenshots of my app to itunesconnect. All the screenshots are in landscape mode (I rotated them using iPhoto). On the itunesconnect page where I uploaded the screenshots they all appeared in landscape mode... fine. Now on another page in itunesconnect they all appeared in portrait mode (and they were squishe...

How to get GeoCoordinates from pictures in iPhone

Hi, I am developing an application which picks photo's from photo library using UIImagePicker. I want to read the geo-coordinates of the photo and use them in my application. Can you point me to any example code on how to do that ?? First of all is it possible to that ?? Any pointers to which classes I should use ?? Regards HIte...

Can I run iPad with 200 thousand record with sqlite ?

Current database have 200 thousand record. I want to make iPad application , can I run 200 thousand record with sqlite ? I don't want to use sqlite because searching is too slow over 32000. Any search engine like lucene for iPhone SDK ? if we can run lucene in iPad that will be awesome because current project is base on lucene. Can you g...