How to make UIScrollView stop immediately?
<p>I just want to scroll only one page then to another.</p>

<p>I set <code>m_pScrollView.pagingEnabled = YES</code> and <code>m_pScrollView.bounces = NO</code> but when I scroll to the edge of the page it goes out of the page range and then back, likes an inertia effect.</p>

<p>I just want it scoll only one page not more. Can anyone help me?</p>

<pre><code>- (void)viewDidLoad {
    [super viewDidLoad];

    m_pScrollView = [[UIScrollView alloc]initWithFrame:CGRectMake(0, 0, 768, 1024)];
    m_pScrollView.delegate = self;
    m_pScrollView.contentSize = CGSizeMake(768 * 3, 1024);
    m_pScrollView.pagingEnabled = YES;
    m_pScrollView.bounces = NO;
    m_pScrollView.alwaysBounceHorizontal = NO;
    m_pScrollView.alwaysBounceVertical = NO;


    Myview *myview = [[Myview alloc]initWithFrame:CGRectMake(0, 0, 768, 1024)];
    myview.backgroundColor = [UIColor redColor];

    Myview *myview2 = [[Myview alloc]initWithFrame:CGRectMake(768, 0, 768, 1024)];

    myview2.backgroundColor = [UIColor blueColor];
    Myview *myview3 = [[Myview alloc]initWithFrame:CGRectMake(768 * 2, 0, 768, 1024)];
    myview3.backgroundColor = [UIColor grayColor];


    [m_pScrollView addSubview:myview];
    [m_pScrollView addSubview:myview2];
    [m_pScrollView addSubview:myview3];
    [self.view addSubview:m_pScrollView];
}
</code></pre>
