---
title: "scrollViewWillEndDragging(_:withVelocity:targetContentOffset:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/uiscrollviewdelegate/scrollviewwillenddragging(_:withvelocity:targetcontentoffset:)"
---

# scrollViewWillEndDragging(_:withVelocity:targetContentOffset:)

Tells the delegate when the user finishes scrolling the content.

## Declaration

```swift
optional func scrollViewWillEndDragging(_ scrollView: UIScrollView, withVelocity velocity: CGPoint, targetContentOffset: UnsafeMutablePointer<CGPoint>)
```

## Parameters

- `scrollView`: The scroll-view object where the user ended the touch.
- `velocity`: The velocity of the scroll view (in points per millisecond) at the moment the touch was released.
- `targetContentOffset`: The expected offset when the scrolling action decelerates to a stop.

## Discussion

Discussion Your application can change the value of the targetContentOffset parameter to adjust where the scrollview finishes its scrolling animation.

## See Also

### Responding to scrolling and dragging

- [scrollViewDidScroll(_:)](uikit/uiscrollviewdelegate/scrollviewdidscroll(_:).md)
- [scrollViewWillBeginDragging(_:)](uikit/uiscrollviewdelegate/scrollviewwillbegindragging(_:).md)
- [scrollViewDidEndDragging(_:willDecelerate:)](uikit/uiscrollviewdelegate/scrollviewdidenddragging(_:willdecelerate:).md)
- [scrollViewShouldScrollToTop(_:)](uikit/uiscrollviewdelegate/scrollviewshouldscrolltotop(_:).md)
- [scrollViewDidScrollToTop(_:)](uikit/uiscrollviewdelegate/scrollviewdidscrolltotop(_:).md)
- [scrollViewWillBeginDecelerating(_:)](uikit/uiscrollviewdelegate/scrollviewwillbegindecelerating(_:).md)
- [scrollViewDidEndDecelerating(_:)](uikit/uiscrollviewdelegate/scrollviewdidenddecelerating(_:).md)
