iphone-sdk-3.0

How to find if NSTimer is active or not?

I have a something like this: NSTimer* timer = [NSTimer scheduledTimerWithTimeInterval:1.0 target:self selector:@selector(updateCountdown) userInfo:nil ...

MPMusicPlayerController and playing a bundled song

hai all, how can i play a song file bundled with the application using MPMusicPlayerController ? code that i tried, NSString *url = [[NSBundle mainBundle] pathForResource:@"song1" ofType:@"mp3"]; MPMusicPlayerController *myMusicPlayer=[[MPMusicPlayerController alloc] initWithContentURL:[NSURL fileURLWithPath:url]]; [myMusicPlayer p...

Search and display buisness locations on MKMapView

Hello, I'm trying to find a way to search for a business, such as "grocery stores" and display them on a google map around the users current location. This used to be pretty simple with the old URL style of launching the apple map location but I can't find out how to do it with the MKMapView. I understand that I'll need to use the MKA...

iPhone SDK - check iPod playlist to see whether there is a next track to skip to

Is there a way to inspect the current playlist from MPMusicPlayerController to see whether there is another track to play in the queue? It's possible to detect this after as skipToNextItem will stop playback and change playbackState, but I want to find out before, so I can disable the skip track function if there are no more tracks to s...

How to design UIPageControl app?

Is the correct way of designing a UIPageControl based app still like the PageControl sample (7/3/2008) on the Apple developer site...built for OS 2.0? In that sample, it uses the same xib and controller for the pages. If I have five pages, can I use five different controller/xib pairs for each page? Is that as straight forward as it s...

setting the default applications for a file type in iphone

Hai all, In my iphone application i want to open a my custom application(available in the iphone) when the user tapes on a particular type file sent by email or MMS , for example, if i sent an music file (via email or MMS) with a custom extension (for eg: .muc) i want to open my application (lets say myMusicPlayer) to play that fil...

will APNS generate new device token every time for a single device?

I want to know that does apple's Push Notification Server generate new device token every time when requesting from a same device? ...

how to handle multiple devices when using Push Notification?

I am developing an application in which i want to use push notification service.i have a sever.now i want to know that how do i handle multiple devices? is there a unique device id/name for every iphone? suppose i want to delete request for a specific device token,so how do i handle multiple users? is there a way i can generate unique na...

how to save and retrieve date+time into sqlite3 database?

i want to save current date+time into database and also want to retrieve it. i know that in objective-C we cannot save date+time directly. i have double as a field into database and currently I'm saving date by converting it into double. here is the method for converting date into double- currentDate=[NSDate date]; startDate=(double)...

from where we send json payload when using APNs?

i want to know that when we want to use push notification service.From where we send json payload, from our app or it may be generated on server? if it has to be sent from our app then how do we send json payload+device token to our own web server? ...

Hiding the Quick Time logo and controls when an audio file is played using MPMoviePlayerController

Hai all, in my application i need to play a streaming audio, i used MPMoviePlayerController to play the audio, it works fine, but i don't want the Logo and controls appearing on the screen( like playing in the background). is there any way to hide the logo and controls ? thanks ...

IPhone P2P - Problem with p2p connection when 3 iphones are searching

Here's the situation, I made a game that use GKSessionModePeer to do the multiplay mode, but the problem is happened when I use three iphones, just call them A,B,C when A and C searched B,they choose B at the same time, then the screen change to the waiting for apply page, at this moment,problem happen!!!!! A and C start the game sudden...

MultiView application for iphone

Hi All, I am new to the iphone development and have to develop a multivew application for the same. I want to do the following: On click of a button in the main window; we have to open a new view that has a toolbar with items & a tab bar in it; with some text data in between from a service. If the user click on any of the toolbar ite...

iPhone > Submitting a web form, handle cookies..

Hey all, I'm not at all sure where to get started with the following. Bascially the scenario Is, from my iPhone app I want to be able to login to a web form (via username/password combo) and perform another action. I want the process to be able to handle session persistence via cookies. My first thoughts were to look at going down the ...

Choose specific localization on an iPhone app

How can I let the user choose a specific localization in my app? I have a book and I'd like the users to be able to read all the different translations of it. ...

How do I detect if device doesn't have a sim card using iphone sdk?

i am using these methods to get my location.all works fine in simulator.but on real device it runs very fast.how do i slow this down,also how do i show error only once if the device have not sim inserted and also for user denied to use current location. here are the methods-- -(void)GetCurrentLocation { // Create the location manager i...

how to add hours in a nsdate?

i have a date converted to double value and saved in database.now i want to compare if cureentdate > myDataBaseDate+8 hours. means i want to get 8 hours more added in my database date. i'm converting date into double values.so how do i get 8 hours later time from my database saved date. how do i compare if(currentDateTime>DateFromdatabas...

HTML email loses formatting after being sent from iPhone program

I'm using MFMailComposeViewController in the iPhone SDK to bring up the mail dialog to send an HTML formatted email. The contents of the message body is being read from an HTML file which is generated in the app and saved on the filesystem. The email looks fine in the send mail dialog and all of the CSS formatting is there. However, afte...

MPMediaPickerController, MPMediaItems, and NSData

I was wondering if Apple allowed you to access the MPMediaItem's raw data as an NSData object. If you can, thats great and I would like to know how. If you cannot, then Apple is way too over-protective, and my app that i started is utterly useless. Also if you cannot, Is there any hacky workarounds? I don't care if Apple doesn't accept m...

ASIHttpRequest NetworkQueue problem

Hey Guys, I want to use the ASIHttprequest library to download some files, I am testing with their code and it is not working while the same code works on their sample this is my code to call their view QueueViewController *queueViewController = [[QueueViewController alloc] initWithNibName:@"Queue" bundle:nil]; [self.vie...