2012-03-18 6 views
0

UIWebview에 로컬 파일 인 example.pages를로드하려고합니다. 나는 이것으로 시도했다UIWebview에서 .pages (iWork)를로드하는 방법은 무엇입니까?

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

그러나 작동하지 않는다. 누구?

답변

-2

페이지 문서가 HTML이 아닙니다. UIWebView에서로드 할 수 없습니다.

+0

그래서 .pages 문서를로드하는 방법은 무엇입니까? – acid

+0

나는 그것을 뒤로 가져 간다. 가능할 수도 있습니다. [이 관련 질문] (http://stackoverflow.com/questions/2543295/is-there-any-apis-to-displayed-the-workfiles-in-iphone) 및 [QA 1630] (http : /developer.apple.com/library/ios/#qa/qa1630/_index.html). –

+0

문서를 zip 파일로로드하려고 시도했지만 example.pages.zip 이지만 여전히 작동하지 않습니다. (Keynote, Numbers 및 Pages 도큐멘트는 iWork '06 또는 iWork '08로 작성해야합니다 .iWork '06 및 iWork '08 도큐멘트는 도큐멘트 패키지이며, UIWebView가이를 인식 할 수 있도록 ZIP 압축되어야합니다. 두 확장자를 모두 파일에 유지해야합니다 presentation.key.zip, spreadsheet.numbers.zip 또는 paper.pages.zip과 같은 이름). – acid