Wow! Thanks for the code and tutorial this great example of how great community support can be! Works like a charm.
There is a bit of a declaration mixup though. Change pdfURL to pdfUrl to make it integrate with the code from the first example
For people who want to know where to place the resource code; replace the viewDidLoad in your [yourname]viewController.m file with this:
PHP Code:
- (void)viewDidLoad {
[super viewDidLoad];
pdfUrl = [NSURL fileURLWithPath:[[NSBundle mainBundle] pathForResource:@"[yourpdffilenamehere" ofType:@"pdf"]];
[webView loadRequest:[NSURLRequest requestWithURL:pdfUrl]];
}
As said, I changed pdfURL to pdfUrl in the example code supplied to integrate it with the tutorial by danielb21