如何在UIWebView iOS 7中加载.pages文档?

时间:2014-04-02 16:32:04

标签: objective-c ios7 webview uiwebview

我在iOS 7中加载.pages文档时遇到问题。我尝试使用此代码

NSString *path = [[NSBundle mainBundle] pathForResource:str  ofType:@"pages" inDirectory:@""];
NSURL *url = [NSURL fileURLWithPath:path];
NSURLRequest *request = [NSURLRequest requestWithURL:url];
[webview loadRequest:request];

然后我尝试了

-(void)loadDocument:(NSString*)documentName inView:(UIWebView*)webView
{
    NSString *path = [[NSBundle mainBundle] pathForResource:documentName ofType:nil];
    NSURL *url = [NSURL fileURLWithPath:path];
    NSURLRequest *request = [NSURLRequest requestWithURL:url];
    [webView loadRequest:request];
}

// Calling -loadDocument:inView:
[self loadDocument:@"mydocument.rtfd.zip" inView:self.myWebview];

但我想在集合视图中加载超过50个.pages文档,我收到此错误:

  

警告:无法为断点1.1设置断点站点0x11428984c:无法读取断点地址处的内存。

0 个答案:

没有答案