iOS目标C:显示RTF文档 [英] iOS Objective C: Display RTF document
本文介绍了iOS目标C:显示RTF文档的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想在视图中显示RTF文档。本文档将在Microsoft Word中开发并包含图像。
I want to show a RTF document in a view. This document will be developed in Microsoft Word and will contains images.
使用提供的标准例程执行此操作的最佳方法是什么?
What is the best way to do this using standard routines provided?
我真的希望示例代码从bundle中加载RTF文档。
亲切的问候,
Jason
I would really like sample code to load a RTF document from the bundle. Kind Regards, Jason
推荐答案
UIWebView打开.rtf文件。尝试类似
UIWebView opens .rtf documents. Try something like
NSURL *rtfUrl = [[NSBundle mainBundle] URLForResource:@"MyFileName" withExtension:@"rtf"];
NSURLRequest *request = [NSURLRequest requestWithURL:rtfUrl];
[_webview loadRequest:request];
参见 UIWebView文件类型的文档。
这篇关于iOS目标C:显示RTF文档的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文