UIWebView memory optimization

Discussion in 'iOS Programming' started by XcodeNewb, Mar 10, 2009.

  1. XcodeNewb macrumors member

    Joined:
    Feb 6, 2009
    #1
    As we know the iPhone will keep Safari running in the background which usually consumes about 17-24 MB of the ram at any given time.

    If I have an application that opens a view that is basically a UIWebView with a URL loaded to it, it seems to take about 15 MB of ram to do this.

    Is there any way to load a UIWebView and not take up so much of the system RAM to do it? All I am doing it a:

    Code:
    [[UIApplication sharedApplication] openURL:[NSURL URLWithString:myURL]];
    
    Does anyone have experience trying to optimize memory usage with a UIWebView?

    Thanks
     
  2. jnic macrumors 6502a

    Joined:
    Oct 24, 2008
    Location:
    Cambridge
    #2
    Other than unloading it when you're not using it, and avoiding memory-hungry web pages (images, JavaScript etc.), I'm afraid not.
     

Share This Page