-4
-(IBAction)Back:(id)sender{

NSString *path = [NSString stringWithFormat:@"%@%@",
[[NSBundle mainBundle] resourcePath],
@"/Dtmf-star.wav"];

//declare a system sound id
SystemSoundID soundID;

//Get a URL for the sound file
NSURL *filePath = [NSURL fileURLWithPath:path isDirectory:NO];

//Use audio sevices to create the sound
AudioServicesCreateSystemSoundID((CFURLRef)filePath, &soundID);

//Use audio services to play the sound
AudioServicesPlaySystemSound(soundID);
[Buttonback setImage: nil forState:UIControlStateNormal];

int size = [PhoneUrl length];
if (size>0) {
    PhoneUrl = [PhoneUrl substringToIndex:size-1];
}
dspText.text = PhoneUrl;

}

this i have done..i am able to delete one digit but if there is more than one digit application get crash... It is working fine in ios6.

4

1 回答 1

0

Unless you post almost the complete code, these kind of problems are really hard to solve for us. But it is propably a good idea to run the program in combination with a debug function monitoring the memory, since your problem most likely has something to do with that.

于 2013-09-25T05:58:06.827 回答