title: Calculating actual size of UITableView
body: <p>I need to scroll my UITableWay programmatically. Scrolling is performed when user touches a button. I want my UITableWay scroll up until the bottom of the actual table reaches the bottom of the table's frame. I thought it would be easy to implement by doing something like this:</p>
  
  <pre><code>static CGFloat offset;
  
  - (IBAction)pageUpClick:(id)sender
  {
  if (offset &lt; ([rankingTableView numberOfRowsInSection:[rankingTableView numberOfSections] - 1] * rankingTableView.rowHeight) - rankingTableView.frame.size.height)
       {
         offset += 10.0;
         [rankingTableView setContentOffset:CGPointMake(0, offset)];
        }
   }
  </code></pre>
  
  <p>but it doesn't work. The table just goes up even when the rows are over the bottom of the frame. i cannot find the actual size of my table.... but obviously it is quantity of rows * row height. since i want my scrolling stop when both the bottom of the table and the bottom of its frame lies on the same line i'm substracting the height of the frame. And all in vain. My only possible explanation is maybe i'm using wrong section number (i'm assuming it to be [rankingTableView numberOfSections] - 1 cause i got just one section ) ... but how can i check it? Any ideas? Thanks in advance</p>