问题
I am creating an 0800 diverting app which allows the user to use his/her monthly credit to phone an 0800 number diversion service rather than pay extra by dialling in the 0800 number directly to the native phone app. Basically XCode will take the 0800 number from a label and will phone the conversion number (01212842800) then straight after, it will dial in to the keypad (on the same call), the 0800 number from the label.
If you know what I mean, how would I do this please?
回答1:
See this question on SO: Programmatically Dial a Phone number and pass DTMF using the iPhone SDK
It appears that you cannot dial a number programmatically, but you can achieve what you're trying to do by using ","s in the number that you call.
EX:
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tel:01212842800,,,,,,,,,NUMBER_HERE"]];
With the commas acting as pauses.
来源:https://stackoverflow.com/questions/7058872/how-would-i-dial-a-number-and-then-key-in-numbers-to-the-dialpad-five-seconds-af