I use UIWebView to open local Office file formats (ppt, xls, doc) and iWork (numbers, pages, key) that are less than 5 MB in size. To download them, I just do:
NSURL *url = [NSURL fileURLWithPath:filepath]; NSURLRequest *requestObj = [NSURLRequest requestWithURL:url]; [myWebView loadRequest:requestObj];
When loading some of these files into a web view (especially ppts with a large number of images in them), the memory usage increases to almost 35 MB, which leads to the failure of my application. I have looked through various iOS forums, but have not really found a solution. Uses loadData: MIMEType: textEncodingName: baseURL: help save memory space or any other tricks to use UIWebView?
memory-management ios ios4 uiwebview
Sushant
source share