Height of UIWebView minus 44px programmatically?

2 Solutions Collect From Internet About “Height of UIWebView minus 44px programmatically?”

Save your old frame like this:

CGRect oldFrame = WebView.frame;

Then set the new frame :

CGRect newFrame =CGRectMake(oldFrame.origin.x, oldFrame.origin.y, oldFrame.size.width, oldFrame.size.height-44);
[WebView setFrame:newFrame];

Thats it 🙂

I guess this should be enough.

webView.frame = CGRectMake(webView.frame.origin.x, webView.frame.origin.y, webView.frame.size.width, webView.frame.size.height - 44);