0
我有一個相當簡單的問題。如何在Caches目錄中打開PDF文件?如何從Caches目錄加載PDF?
我唯一的代碼是在應用程序包中打開PDF文件。
myDocumentRef = CGPDFDocumentCreateWithURL((CFURLRef)[NSURL URLWithString:@"Matsedel.pdf"]);
NSURL *pdfURL = [[NSBundle mainBundle] URLForResource:@"Matsedel.pdf" withExtension:nil];
myDocumentRef = CGPDFDocumentCreateWithURL((CFURLRef)pdfURL);
myPageRef = CGPDFDocumentGetPage(myDocumentRef, 1);
我會認爲這很容易做,但我無法弄清楚。謝謝。