是否有任何特殊方法可以在UIwebview上加载.xlsb(excel二进制格式)。我可以加载.xlsx,但不能加载.xlsb。
NSString *path = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) lastObject];
path=[[path stringByAppendingString:@"/"]stringByAppendingString:@"myFile.xlsx"];
NSURL *url=[NSURL URLWithString:[path stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];
NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
[self.webPage loadRequest:requestObj];
答案 0 :(得分:3)
不幸的是,UIWebView不支持xlsb文件,只支持xlsx文件。为了进一步参考,Apple在此列出了所有支持的文档类型: https://developer.apple.com/library/ios/qa/qa1630/_index.html