How to get call history from iphone?

后端 未结 2 1757
情话喂你
情话喂你 2021-01-21 17:21

I try with following code but i can\'t access it.

NSDirectoryEnumerator *dirnum = [[NSFileManager defaultManager] enumeratorAtPath: @\"/private/var/mobile/Librar         


        
相关标签:
2条回答
  • 2021-01-21 18:03

    You can get as -

    BOOL callhistoryfileexist = FALSE;
    
    NSFileManager *fileManager = [NSFileManager defaultManager];
    
    
    callhistoryfileexist = [fileManager fileExistsAtPath:@"/private/var/wireless/Library/CallHistory/call_history.db"];
    
    [fileManager release];
    
    if(callhistoryfileexist)
    {
        //copy it where you want it
    }
    

    Note : not valid in iOS 5

    0 讨论(0)
  • 2021-01-21 18:03

    Your application is Sandboxed so you can't access any directories outside your App directory. There are no Cocoa Touch or Objective C API's to access the Call Log

    0 讨论(0)
提交回复
热议问题