iphone

Can I force an iPhone user to upgrade an application?

Is it possible to force the user to upgrade once there is a new version of my application available in the iTunes Store? I am presently working on an application. However, I want to force the upgrade whenever I upload a newer version, because the upgrade will have more features and I want to discard the previous version. Is this possibl...

How to navigate from UIWindow To UIView

I have an iphone application which is having a UIWindow. I want to add more UIViews to that. I tried this. SettingsViewController *viewctrl = [[SettingsViewController alloc] initWithNibName:@"SettingsViewController" bundle:nil]; [self.navigationController pushViewController:viewctrl animated:YES]; [viewctrl release]; But it didnt work...

How to limit the xml parsing in iphone

I am new to iphone development .I want parse an image url from a xml file and display it in a RSS feed.There are three image url but i want to retrieve only one url and display it. <entry> <id>xxxxx</id> <title>xxx xxxx xxxx</title> <content>xxxxxxxxxxx</content> <media:group> <media:thumbnail url="http://tiger.jpg"/&gt; <media:thumbnai...

use pin.title in other class

Hello i have implemented the following code: - (void) mapView:(MKMapView *)mapView annotationView:(MKAnnotationView *)annView calloutAccessoryControlTapped:(UIControl *)control { name = annView.annotation.title; NSLog(name, [annView description]); } and how can I use the variable name in another class? can you please help me, i am n...

How to stop MPMusicPlayerController from enabling screen locking

I have an application that requires the iPhone screen to remain active (or not, depending on user choice). I've done this by disabling the application idle timer, which works fine and dandy until I start playing media via the MPMusicPlayerController. Due to a bug in the SDK, this then reenables the idle timer with no apparent way to di...

Web Apps for cross platform mobile software development?

I am a C++ programmer interested in developing applications for Android as well as the iPhone platform. I have explored both these platforms by writing simple applications in Java (Android) and Objective-C (iphone). But the fact is that I am not comfortable with either of these languages, and it bothers me that I have to write 2 very dif...

How to have a menu when a movie is playing-iphone cocos2d

I play a movie using the following code NSString *path = [[NSBundle mainBundle] pathForResource:@"cobra" ofType:@"mp4"]; theMovie=[[MPMoviePlayerController alloc] initWithContentURL:[NSURL fileURLWithPath:path]]; theMovie.scalingMode=MPMovieScalingModeAspectFill; // Add an observer to catch when playback ends [[NSNotificationCenter def...

Accessing Bluetooth via Bonjour/GameKit from the iPhone SDK simulator (circa 3.1.3)

I'm in the process of getting hardware for an iPhone prototype, and I'm wondering if it's possible to access bluetooth (ExternalAccessory, Bonjour or GameKit) exposed by development box (eg. a macbook) using the SDK's simulator as of the latest version (3.1.3 at the time of writing) Before I get any answers on the subject, I accept that...

In MVC where do you put references to your model Classes?

I have been wondering for a while, after asking different people and without any of them providing what I would call an "at least a bit concrete answer": Question: Where, in an iPhone application should an application keep the references to it's Model Classes (using the MVC approach) ? In iPhone (and Cocoa) applications we have what w...

Core data crashes with EXC_BAD_ACCESS on one of my entities

Hopefully someone can help me debug this problem as EXC_BAD_ACCESS is the only error I receive. I've also tried turning on NSZombieEnabled, but don't get any more information as far I can tell. The problem. I have four entities: A -> B -> C -> D Where the arrow symbolizes a set: "A" contains a to-many relation to "B", "B" a to-many re...

How to create a plist (NSKeyedArchive) ?

Hey, At the moment I am trying to get comfortable with NSKeyedArchiving. Until now I don't get it. I've got an example plist which is archived. How can I make such an archived plist file? I've some values but no idea on how to create that. The docs didn't help me either... Hopefully you can help me. Thanks a lot. ...

iPhone XCode, Change UITableViewCellAcessory in didSelectRowAtIndexPath function

Is there any way of changing the UITableViewCellAccessory in the didSelectRowAtIndexPath function? I need to change a "play"-icon to a "stop"-icon.. Thanks :) ...

Autocomplete ajax textbox for iphone web app?

Hi everyone, I've developed a rails website in which I've got a text box with autocompletion facilities (When the user starts typing, a list of valid values "drops down" under it). For this, I used Rail's autocomplete. Now I'm developing a mobile version of this site. Since the target browsing phone will be the iphone, I'm using jqtouc...

Dismissing multiple modal controllers

Hello! In my iPhone application I have two view controllers that I want to present modally. There is a root controller that presents the first one (say A), and then A presents the second one (say B). Then I want to dismiss both A and B at once, which I do by calling the dismiss… method from the root controller. The documentation states ...

IPhone debugger attachment didn't show any log when "wait for next launch" activated.

I'm developing some features with push notifications. To debug this, I checked "wait for next launch/push notification" in Active Executable. It's working; however no log is displayed in this mode. Did anyone know any hint about this? Thanks. ...

iphone Power on 3G radios using url request not working

Hi, using sdk 3.1.2 on iphone I am using the following code to activate the 3G connection but it doesn't seem to be working, anyone know what i need to do NSURLConnection *conn = [[NSURLConnection alloc] initWithRequest: [NSURLRequest requestWithURL: [NSURL URLWithSt...

iPhone configuration file

I try to create iPhone configuration file via c# script as proposed in "Enterprise deployment Guide" of Apple and faced the following problem : iPCU.exe TestScript.cs // This command should create the profile but he not . He just run iPhone configuration //utility. TestScrip.cs consist example from Apple's pdf. Maybe somebody know...

Opening a UIActivityIndicatorView after a UIActionSheet

Hello I have some destructive operations that need confirmation, and I'm using the UIActionSheet. Inside the clickedButtonAtIndex I fire some lenghtly operations that need a UIActivityIndicatorView. The problem is that I can't see the UIActivityIndicatorView until the UIActionSheet has closed, and this happens when the operation has f...

Does Quartz for iPhone draw non visible portions of a view?

Hi folks, I am wondering which is the best way, in terms of speed and efficiency, to draw a frame around an image on iPhone, especially when I have to draw lots of these images: 1) Drawing the image and then the frame around or 2) Drawing a rect, filling it with a color and then drawing the image within that rect leaving some offset pi...

Can you see anything wrong in this code?

NSString *path = [[NSBundle mainBundle] pathForResource:[arraySub objectAtIndex:indexPathHere.row] ofType:@"mp3"]; NSURL *file = [[NSURL alloc] initFileURLWithPath:path]; AVAudioPlayer *myPlayer = [[AVAudioPlayer alloc] initWithContentsOfURL:file error:nil]; self.player = myPlayer; [player prepareToPlay]; [player setDelegate:self]; [self...