# CreateDragDropOperation from Class Reference not possible?

**URL:** <https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848>\
**Category:** UI\
**Tags:** reference, drag-and-drop, unreal-engine, Blueprint, question, UMG\
**Created:** [August 24, 2023, 11:39am UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848 "2023-08-24T11:39:46Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![BDC\_Patrick](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bdc_patrick/32/1104221_2.png) [@BDC\_Patrick](https://forums.unrealengine.com/u/BDC_Patrick)\
**Post date:** [August 24, 2023, 11:39am UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/1 "2023-08-24T11:39:46Z")

</div>

Hi there…

today I tried to make my Draggable Button more modular… so I wanted the DragDropOperation Class being an exposed variable and create the DragDropOperation (DDO) from that…

This is what the DDO Create looks like:

 ![image1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/1/f/2/1f2860f3fdfd36f89ba0474eeb3474f41df3ab46.png)

As you can see… I also added a function to get the actual class from variable… and Return that exact class type (BDC\_DragDropOperation).  
All my future DDOs will be child classes of BDC\_DragDropOperation…

The ConstructDDO Class is this:

 ![image3](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/4/c/f4ce107081ebf53cf36ae46ae36f759b0a2882f0.png)

Now the interesting thing:  
When I link the Return of that function to the class Input of the CreateDDO… The DragAndDrop functionality gets broken and is not working anymore…  
I really need to hardcode the Class into the CreateDDO node (as on the first screen) to have a functional Drag & Drop…

Is this a Bug? A forgotten limitation that you are not allowed to use class references as Input for the CreateDDO node?

PS.: Interesting side fact… when I link the return to the CreateDDO… the Parameters (SourcePosition, SourceWidget, SourceOffset) of the CreateDDO are the same… so… the returned class gets registered correctly as a reference to a BDC\_DragDropOperation Class…

Any advice on how to make that possible… would be welcome 😃

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [August 24, 2023, 3:32pm UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/2 "2023-08-24T15:32:42Z")

</div>

> [@BDC\_Patrick](#):
>
> Is this a Bug? A forgotten limitation that you are not allowed to use class references as Input for the CreateDDO node?

Yeah, just tried that and it does not work. Curious.

* * *

It’s not even about class extension, the moment you plug in _anything_, it stops working:

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/b/2/3b2b2f986c5f6b192a46d7cc96ac9d6d992d95c3.png)

This is the default base DDO.

---

<div class="post-metadata">

**Author:** ![BDC\_Patrick](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bdc_patrick/32/1104221_2.png) [@BDC\_Patrick](https://forums.unrealengine.com/u/BDC_Patrick)\
**Post date:** [August 24, 2023, 3:46pm UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/3 "2023-08-24T15:46:45Z")

</div>

I sure can make a workaround by using an Enum, a Switch and multiple CreateDDO Nodes… each with a Switch corresponding Class…  
But… That’s a but frustrating to setup and not very/easy modular…

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [August 24, 2023, 3:50pm UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/4 "2023-08-24T15:50:54Z")

</div>

> [@BDC\_Patrick](#):
>
> I sure can make a workaround by using an Enum, a Switch and multiple CreateDDO Nodes…

If I needed this kind of functionality, I’d start working _around_ it, too.

* * *

Also, with custom DDO, it says it will return custom OP. It does not.

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/2/1/d21cd880adb57436cff6c7625771ba8ef2ea761f.png)

My gut feeling tells me this has always been bugged or working as intended and was never supposed to be used like this, nothing in between. This is really confusing.

---

<div class="post-metadata">

**Author:** ![BDC\_Patrick](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bdc_patrick/32/1104221_2.png) [@BDC\_Patrick](https://forums.unrealengine.com/u/BDC_Patrick)\
**Post date:** [August 24, 2023, 3:57pm UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/5 "2023-08-24T15:57:59Z")

</div>

so you mean, When the CreateDDO returns the base DDO Class… one should cast to a specific Base class after the CreateDDO, to proceed with further adjustments?

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [August 24, 2023, 3:59pm UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/6 "2023-08-24T15:59:08Z")

</div>

You should not need to cast in the first place. It simply does not work for as long as anything is plugged in as Class. Sorry, no idea what’s up with this.

---

<div class="post-metadata">

**Author:** ![BDC\_Patrick](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bdc_patrick/32/1104221_2.png) [@BDC\_Patrick](https://forums.unrealengine.com/u/BDC_Patrick)\
**Post date:** [August 24, 2023, 5:00pm UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/7 "2023-08-24T17:00:42Z")

</div>

The Bug Report Form crashes all the time… can’t create one…

Strange thing… No one recognized this 🤔

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [August 24, 2023, 6:52pm UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/8 "2023-08-24T18:52:00Z")

</div>

I looked in the issues DB, couldn’t find anything. Google does not seem to know either. Chances are you’re the first person to ever run into this.

---

<div class="post-metadata">

**Author:** ![BDC\_Patrick](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bdc_patrick/32/1104221_2.png) [@BDC\_Patrick](https://forums.unrealengine.com/u/BDC_Patrick)\
**Post date:** [August 25, 2023, 8:55am UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/9 "2023-08-25T08:55:21Z")

</div>

I reported a Bug for this…

---

<div class="post-metadata">

**Author:** ![system](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/1/3/713c9d3f58553f0de89543d76a8a3a2779dc9fa4.png) [@system](https://forums.unrealengine.com/u/system)\
**Post date:** [September 24, 2023, 8:55am UTC](https://forums.unrealengine.com/t/createdragdropoperation-from-class-reference-not-possible/1270848/10 "2023-09-24T08:55:56Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
