开发者

Generate Paginated PDF from UIWebView

开发者 https://www.devze.com 2023-02-12 06:20 出处:网络
I\'ve got a UIWebView that I\'m using to display a stylized NSString of HTML that I\'m generating.I\'d like to be able to email a paginated PDF of the displayed page.

I've got a UIWebView that I'm using to display a stylized NSString of HTML that I'm generating. I'd like to be able to email a paginated PDF of the displayed page.

Right now, I can use the iOS 4.0 printing features to print a nice, paginated representation of all the text in the UIWebView. Can I do the same, but rather than print the PDF, generate an NSData object (or a file in the sandboxed file system) from the HTML string?

I can already generate an image of the UIWebView, but this开发者_JAVA技巧 doesn't paginate easily and requires a lot more work than I think should be necessary to do this.

Thanks.

0

精彩评论

暂无评论...
验证码 换一张
取 消