iphone

Location services

I have in plenty of Core Location based apps that before triggering the code for location services an alert pop up and warns user that the app is going to use their current location. Is this a in-built feature of Core Location or we need to implement it before calling API? ...

Iphone Crash log not symbolicating UIKit calls

Has anyone ever seen a crash log like this before where the UIKit and other system libraries do not get symbolicated? One of our apps is having an issue with crashing on launch but only a small number of users (like 5) are experiencing the problem. (To my understanding the default.png is displayed and then it crashes) and we have been un...

Game Center API + In-App Purchases API = Two different user accounts for a single app?

Hello. If I have an app that supports Game Center and I'd like to provide Achievements for completing a puzzle pack that's sold as an in-app purchase, how do I sync the iTunes account that's being charged for the in-app purchase with the Game Center user account that's doing the buying? As I understand it, they're two separate user acc...

Danish characters vs. non-danish characters

Hi there all you good people. I'm having a hard time with this iPhone SDK thing. I want to show a text as an html file with a picture. But the thing is, that with the first way I can't get the picture shown only with danish characters and the second way the picture is shown but with no danish characters. In the second approach I can us...

- (void)applicationDidEnterBackground:(UIApplication *)application

Can i use below method somewhere other than AppDelegate ?if yes how? - (void)applicationDidEnterBackground:(UIApplication *)application ...

Possible to parse this html with xpath?

Hello, I am working on gather sports statistics for a personal hobby project. I found this site with all the info I need:file:///Users/JohnJNichols4/Desktop/view-source%20cluster.leaguestat.com%20download.php%20client_code=ahl&file_path=daily-report%20daily-report.html Am I able to parse this site with xpath? I only have experience (...

Switching Content Views Issue

I'm attempting to switch views with an iPhone application- I have a parent view controller, SuperviewController, and then two views that I want to switch within that parent view, MainMenuController and MainGameController. *EDIT*: I am now using navigation controllers: SuperviewController.m viewDidLoad self.mainMenuController = [[MainM...

iPhone Mobile Safari: Portion of content scales by it self.

Really, wondering and don't know why, on the initial load, the "<'p'>" element that holds content is scaled up, the fontsize, if i change orientation of the device it will then adjust scaling and keep it at declared font size that originally was intended, but that initial load. any ideas why? ...

Localizable.strings woes

My Localizable.strings file has somehow been corrupted and I don't know how to restore it. If I open it as a Plain Text File it starts with weird characters that I can't copy here. If I leave the file be the app builds. If I make any changes either the values aren't interpreted properly or I get an error at compile time. Localizable.s...

indexSetWithIndexesInRange is not doing what expected

I want to select some objects from an array. Therefore I'm using begin and end indexes of my selection. NSLog(@"start:%d\nend:%d", startIndex, endIndex); NSIndexSet *myIndexes = [NSIndexSet indexSetWithIndexesInRange:NSMakeRange(startIndex, endIndex)]; NSLog(@"%d", [myIndexes lastIndex]); The first NSLog gives me startIndex:49 ...

Turning an NSArray of custom objects into a alphabetically sectioned UITableView with an index?

(hmm.. long title) If I start out with an NSArray of custom objects (each object is a Person) like this: { surname:Allen forename: Woody, surname:Baxter forename: Stanley, surname:Clay forename: Cassius } ..etc.. You can see that the array is already in surname order. How do I use that array to create a a UITableView wit...

Problem dismiss MPMoviePlayerViewController on play error

Hi, I have a problem with the MPMoviePlayerViewController: If the controller can't find the movie at the specified URL it displays a white screen and I can't make it go close. This is how I start the movie player: - (void) playVideo:(NSString*)path { NSURL* url = [NSURL URLWithString:path]; [[NSNotificationCenter defaultCenter] ad...

The iPhone Simulator from xCode 3.2.4 has a problem with sliding!

The problem is shown better in this video I uploaded to youtube. It seems the iPhone simulator doesn't slide the views correctly. It seems to get stuck and the view doesn't return. Like you see in the video, switching between springboard pages doesn't work as it suppose to! I need to make an additional click to make the page go in positi...

Bug in PhotoScroller code from WWDC 2010 Session 104 - Designing Apps with Scroll Views

I am trying to track down a bug in the sample code provided for the WWDC Session 104 - Designing Apps with Scroll Views: "PhotoScroller" It is a mutated while being enumerated error that only happens on occasion when paging from a zoomed image to one of the other images. I am using part of this code in one of my apps and am desperately ...

Create NSArray from plist array

I need to pull out data from a plist array and put it in an NSArray. But it seems to not be working. Here is my main file: NSString *path = [[NSBundle mainBundle] pathForResource:@"htmlData" ofType:@"plist"]; NSMutableDictionary *tempDictionary = [[NSMutableDictionary alloc] initWithContentsOfFile:path]; dictionary = tempDictionary; [...

Should I use a UIButton or a simple UITapGestureRecognizer

I'm creating an iOS user interface with a lot of different UIImageViews that will trigger actions when tapped (once is enough). I have the choice between using UIButtons with a custom view (the image) or just setting up a bunch of UIImageviews with an associated UITapGestureRecognizers. In terms of functionality I get the same expected r...

Advice on google/twitter search from iphone using php/json

<?php header('Content-type: application/json'); $json = file_get_contents("http://twitter.com/status/user_timeline/lindsaylohan.json?count=1"); $temp = json_decode($json); $array = Array(); $array[] = $temp; echo json_encode($array); ?> I have a JSON parser in my iphone app. I'm using the above PHP code to try and search Twitter. Can a...

How to let the user select an image from a google images search on iOS

Is there any way that I can let the user select an image from a google images search and convert it into a UIImage? ...

How to insert an image inside another image in Open GL ES programming?

Hi, i am learning to program in Open GL ES 1.1 for iphone to make 2D game. In my game I need to put panels in the screen and inside the panels i will put the elements. But to be able to do this, I need to know how to put an image inside another in Open GL ES 1.1. I just know how to put directly in the screen according this tutorial h...

Scroll scrollbar in browser without using window.scrollBy

Hi All. I am trying to create a board game using html/css/javascript to be played on the iphone. My board is a 2d grid designed using a table with 128 elements both in height and width and each element is 128x128px. I want the game to start in the center of the board. That is the vertical and horizontal scrollbars roughly in the center o...