How do I programmatically make phone calls on the iPhone?
            Asked
            
        
        
            Active
            
        
            Viewed 7,806 times
        
    3
            
            
        - 
                    You can't make a phone call without letting the user know (and it's a good thing), if that's what you meant. If not, refer to the answers below. – zneak Jul 30 '10 at 05:11
 
3 Answers
9
            Try this:
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel://8005551212"]];
... which will bring up a dialog in which your users will confirm the call.
        esqew
        
- 42,425
 - 27
 - 92
 - 132
 
- 
                    
 - 
                    
 - 
                    2@Sneha: please describe what you're trying to do, and how seanny's answer fails to meet your requirements. – Michael Petrotta Jul 30 '10 at 05:56
 - 
                    
 - 
                    1@Sneha: why do you want some other way? whats the problem with this one..? – Swapnil Luktuke Jul 30 '10 at 06:29
 - 
                    2
 
3
            
            
        I know this is an old post, but I'll give a different answer.
esqew approach works well but it goes straight to the phone app and it doesn't give you a prompt to confirm the number with a call button.
Try this approach and it gives a prompt option.
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"telprompt://1028464023"]];
The only thing that changes is: telprompt on URLWithString. Give it a try.
        Michael Ortiz
        
- 757
 - 1
 - 8
 - 21
 
0
            
            
        Since you don't want to do it the way seanny94 suggests, the only other way is VoIP. Check this question or ask Skype how to do it.
        Community
        
- 1
 - 1
 
        Swapnil Luktuke
        
- 10,385
 - 2
 - 35
 - 58