El Sinior X
El Sinior X

Reputation: 71

How to hang up a call automatically?

I'm very interesting to know how to hang up a call automatically. If I push my call button

(this is it's code):

-(IBAction)callPhone:(id)sender {
    [[UIApplication sharedApplication] openURL:[NSURL URLWithString:phone.text]];
}

I want to hang up the call after 5 seconds automatically. How can I do that?.

Thanks.

Upvotes: 3

Views: 2985

Answers (2)

user1274038
user1274038

Reputation: 11

you can't, you can initiate call from your app but you can't hang up.

Upvotes: 1

Daniel A. White
Daniel A. White

Reputation: 190976

That is outside the scope of the iOS SDK. You can't tell the phone subsystem to do anything. This merely invokes the system to do something.

Upvotes: 3

Related Questions