# UMG - How to disable drag scrolling in a scrollbox?

**URL:** <https://forums.unrealengine.com/t/umg-how-to-disable-drag-scrolling-in-a-scrollbox/413894>\
**Category:** UI\
**Tags:** scrollbox, unreal-engine, question, UMG\
**Created:** [January 6, 2018, 1:12pm UTC](https://forums.unrealengine.com/t/umg-how-to-disable-drag-scrolling-in-a-scrollbox/413894 "2018-01-06T13:12:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Acriax](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/acriax/32/472400_2.png) [@Acriax](https://forums.unrealengine.com/u/Acriax)\
**Post date:** [January 6, 2018, 1:12pm UTC](https://forums.unrealengine.com/t/umg-how-to-disable-drag-scrolling-in-a-scrollbox/413894/1 "2018-01-06T13:12:17Z")

</div>

I have a scrollbox which acts like a container for 3 “pages”. That is, when I click on a button in the interface, I want that scrollbox to scroll exactly 1080 units, which is the size of a page. That part works fine. But I only want it to scroll in those discrete steps. I don’t want the user to be able to drag to scroll 2 and a half page for example.

There is an option to “Allow right click drag scroll”, but there’s no such option for the left mouse button. Visibility: Self Hit Test Invisible doesn’t work to disable drag scrolling.

---

<div class="post-metadata">

**Author:** ![Acriax](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/acriax/32/472400_2.png) [@Acriax](https://forums.unrealengine.com/u/Acriax)\
**Post date:** [January 7, 2018, 2:15am UTC](https://forums.unrealengine.com/t/umg-how-to-disable-drag-scrolling-in-a-scrollbox/413894/2 "2018-01-07T02:15:38Z")

</div>

In my case, I didn’t need the scroll indicator, so I was able to solve it by simply replacing the scrollbox with a canvas and use canvas slot offset instead of scroll offset.

---

<div class="post-metadata">

**Author:** ![Luckaduck131](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Luckaduck131](https://forums.unrealengine.com/u/Luckaduck131)\
**Post date:** [December 24, 2022, 3:20am UTC](https://forums.unrealengine.com/t/umg-how-to-disable-drag-scrolling-in-a-scrollbox/413894/3 "2022-12-24T03:20:06Z")

</div>

I found another way to do this using scroll boxes, which might be helpful if anyone is looking for this after they have implemented scroll boxes instead of a canvas with some offset code.

I added an image that is completely filled with 100% alpha (just a transparent image) in a canvas panel that wraps the scroll box and this new image. I set the z offset of the image to a greater z offset than the scroll box, and I can completely block out all event grabbing because all events are passed to the image.
