Skip to content

Fatal error: Index out of range #8

Description

@MossoIsai

I have a problem when it's just an array image, it marks me the Fatal error: index out of range error in the scrollViewDidScroll method in step 3
if I know that I can help that I was attacking him, thank you and greetings

    func scrollViewDidScroll(scrollView: UIScrollView) {
 //3
        if page <= 1{
            let scrollToObject: AnyObject = objects[Int(objectsCount-3)]
            self.scrollRectToVisible(scrollToObject.frame, animated: false)
        }
        if page >= objectsCount-2{
            let scrollToObject: AnyObject = objects[2]
            self.scrollRectToVisible(scrollToObject.frame, animated: false)
        }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions