# Mouse position not updated while dragging

**URL:** <https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine\
**Created:** [March 3, 2015, 6:59am UTC](https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862 "2015-03-03T06:59:42Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Anslem\_1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Anslem\_1](https://forums.unrealengine.com/u/Anslem_1)\
**Post date:** [March 3, 2015, 6:59am UTC](https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862/1 "2015-03-03T06:59:42Z")

</div>

I’m trying to drag a UI widget around using the drag and drop functions in UMG, the thing is I have particle beam set to follow the mouse around as it’s dragging the widget.

Basically I have the source of the beam set to a static location and the target point of the beam set to the mouse position every tick. If I’m not dragging the widget around it follows the mouse no problem. If however I’m dragging the widget the target point of the beam will only appear at the point where I began dragging the widget, it doesn’t follow the mouse anymore.

Is this a bug? It seems like the mouse position isn’t being updated if you’re dragging stuff around.

---

<div class="post-metadata">

**Author:** ![ja0335](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ja0335/32/560997_2.png) [@ja0335](https://forums.unrealengine.com/u/ja0335)\
**Post date:** [August 27, 2015, 3:17pm UTC](https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862/2 "2015-08-27T15:17:52Z")

</div>

Same problem here

---

<div class="post-metadata">

**Author:** ![charisti](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@charisti](https://forums.unrealengine.com/u/charisti)\
**Post date:** [September 5, 2015, 2:23pm UTC](https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862/3 "2015-09-05T14:23:34Z")

</div>

I have the same problem. Cant find a way to get the mouse position while dragging. Only on drop etc… Anyone found a solution to this yet?

---

<div class="post-metadata">

**Author:** ![ja0335](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ja0335/32/560997_2.png) [@ja0335](https://forums.unrealengine.com/u/ja0335)\
**Post date:** [September 7, 2015, 4:04pm UTC](https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862/4 "2015-09-07T16:04:21Z")

</div>

I have solved this, handling the On Mouse Move Event.

In here you can track the mouse position, as you can see in the attachment.

 ![57564-captura.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/b/5/3b5d1f7bebcfcc99bdedfc841e9531ad89e19b61.png)

---

<div class="post-metadata">

**Author:** ![Servelat](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Servelat](https://forums.unrealengine.com/u/Servelat)\
**Post date:** [December 1, 2015, 1:13pm UTC](https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862/5 "2015-12-01T13:13:49Z")

</div>

There is another similar question:

> **[\[UMG\] - 4.6.1 - Mouse Drag freezing other Widgets.](https://forums.unrealengine.com/questions/160885/umg-461-mouse-drag-freezing-other-widgets.html)**
>
> Did an UMG mouse movement as suggested by Nick. What I’ll say happens on calling this both from the Widget BP as trough a HUD event fired on C++ PlayerTick( ) being this last one “imperative over others” I guess. Everything works fine, but if I...

Seems like there is a workaround for the problem (using UMG cursor) but it does not work for me because of somewhat poor mouse capturing behavior.

There is still a problem with GetMousePosition not returning the correct data in 4.9.2

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_2709d010](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_2709d010](https://forums.unrealengine.com/u/anonymous_user_2709d010)\
**Post date:** [February 22, 2017, 7:26am UTC](https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862/6 "2017-02-22T07:26:30Z")

</div>

This does NOT work while using the drag&drop functionality

---

<div class="post-metadata">

**Author:** ![xlar8or](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/xlar8or/32/710746_2.png) [@xlar8or](https://forums.unrealengine.com/u/xlar8or)\
**Post date:** [June 3, 2017, 10:00am UTC](https://forums.unrealengine.com/t/mouse-position-not-updated-while-dragging/308862/7 "2017-06-03T10:00:56Z")

</div>

Same problem here, want to still be able to corner pan my camera while dragging items and right now i can’t !
