Strong Like Bull
Strong Like Bull

Reputation: 11297

How do I convert a PDF stored as NSData to a CGPDFPageRef?

Please see the following code:

NSString *pdfPath = [documentsDirectory stringByAppendingPathComponent:@"test.pdf"]; 
NSData *myData = [NSData dataWithContentsOfFile:pdfPath];  

How do I convert myData to a CGPDFPageRef?

Upvotes: 3

Views: 1693

Answers (1)

grivescorbett
grivescorbett

Reputation: 1625

Why not use CGPDFDocumentCreateWithURL?

Upvotes: 2

Related Questions