title: Detecting UIScrollView Position
body: <p>I am trying to use a UIScrollView as a navigation device in my iOS application. Basically, I want the application to load specific content, based on the position of a paging-enabled UIScrollView. It is sort of like a navigation wheel.</p>
  
  <p>Currently, I have a two-page (2*320) scrollview, and I am using the <code>scrollViewDidEndDragging</code> delegate method and <code>contentoffset.x</code> to load the appropriate content. I try to determine the position of the scrollview as such:</p>
  
  <pre><code>if (scrollView.contentOffset.x &lt; 320) {
     // Load content 1
      }
  else if (scrollView.contentOffset.x &gt;= 320) {
     // Load content 2
      }
  </code></pre>
  
  <p>My problem is that I either do not understand how to work with contentoffset or it is not suitable to deal with my problem. Either way, I am stuck. Can someone let me know where I went wrong and/or show me a more efficient way to determine scrollview position?</p>
  
  <p>I am stupid, I forgot to mention what the problem is... Basically, I cannot track the position of the scrollview. When I move to the second page it only registers changes if I go over the 620 limit (bounce rightward). But when I go back to the starting position (page 1), it does register the changes. In other words, my tracking is not accurate.</p>
  
  <p>Delegate and everything else is working fine, I log them!</p>