views:

394

answers:

1

Hi all~

I made Documents viewer using UIWebView. Load time is short, because file is in the local.

But scrolling speed make me so crazy. that scroll performance is very poor !!

I made it using so simple code.


NSURLRequest* request = [NSURLRequest requestWithURL:fileURL cachePolocy:NSURLRequestReloadIgnoringLocalCacheData timeoutInterval:60.0];

[self.webView loadRequest:request];

How to enhance the performance of UIWebView????????

A: 

Run your app under Instruments and look for where your performance bottlenecks are. The most likely cause of poor scrolling is that your CPU is maxed out, possibly by some other activity your program is performing.

Alternately, it could have trouble due to complex Javascript in the HTML or illegal HTML. Load your HTML and Javascript into Safari on the Mac and use the Developer's Web Inspector to profile it. Look in the Advanced Preferences for the option to turn on the "Develop" menu.

Rob Napier
Hm, I didn't use HTML for opening a document. Actually, I don't know how to open a document via HTML. Thank you very much Rob, but I think I'm beginner to understand your answer perfectly ^_^;;
oksk