# Inside a widget, instance editable reference to overlay won't stay after compile?

**URL:** <https://forums.unrealengine.com/t/inside-a-widget-instance-editable-reference-to-overlay-wont-stay-after-compile/665106>\
**Category:** UI\
**Tags:** unreal-engine, Widget, question, UMG\
**Created:** [October 8, 2022, 3:07pm UTC](https://forums.unrealengine.com/t/inside-a-widget-instance-editable-reference-to-overlay-wont-stay-after-compile/665106 "2022-10-08T15:07:58Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![BIGTIMEMASTER](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bigtimemaster/32/710746_2.png) [@BIGTIMEMASTER](https://forums.unrealengine.com/u/BIGTIMEMASTER)\
**Post date:** [October 8, 2022, 3:07pm UTC](https://forums.unrealengine.com/t/inside-a-widget-instance-editable-reference-to-overlay-wont-stay-after-compile/665106/1 "2022-10-08T15:07:58Z")

</div>

I have a parent widget class that has instance editable Overlay reference:

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/2/3/023ac9262263153b0e005ff848f9465ff9ca85e9.png)

The result is that child widgets can set an overlay reference like this:  
 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/b/1/b/b1b88f2a0434c2e09dc727143e3dbac43d0f31a0.png)

But on compile, the reference is cleared. Is that normal behaviour? Do I need to set it manually in blueprints? If I do that on Event Construct, it works. But it’s an extra step!

---

<div class="post-metadata">

**Author:** ![SupportiveEntity](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SupportiveEntity](https://forums.unrealengine.com/u/SupportiveEntity)\
**Post date:** [October 8, 2022, 9:39pm UTC](https://forums.unrealengine.com/t/inside-a-widget-instance-editable-reference-to-overlay-wont-stay-after-compile/665106/2 "2022-10-08T21:39:02Z")

</div>

Hey there @BIGTIMEMASTER! This is definitely an odd one. you’re on UE 4.27 correct? I couldn’t replicate the issue on 5.0.3 so I’ll dial it back and check it out there. That’s definitely not intended behavior. Are there any log messages after you compile?

---

<div class="post-metadata">

**Author:** ![BIGTIMEMASTER](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bigtimemaster/32/710746_2.png) [@BIGTIMEMASTER](https://forums.unrealengine.com/u/BIGTIMEMASTER)\
**Post date:** [October 8, 2022, 9:55pm UTC](https://forums.unrealengine.com/t/inside-a-widget-instance-editable-reference-to-overlay-wont-stay-after-compile/665106/3 "2022-10-08T21:55:05Z")

</div>

Hey thanks for the help. Nothing remarkable in the output log:

> BlueprintLog: New page: Compile MainMenu  
> LogUObjectHash: Compacting FUObjectHashTables data took 4.11ms

that’s all that was generated after setting a reference in the dropdown and then pressing compile.  
Another note of interest, when pressing compile the selection is lost. What I mean is:  
 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/7/4/3745f2409d05ebb22f22a5555dc80d1980206c52.png)  
if you have something selected in the hierarchy and then press compile, the selection is zeroed out to nothing. I just mention that because it also seems like suspect behavior and could possibly be related?

---

<div class="post-metadata">

**Author:** ![SupportiveEntity](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SupportiveEntity](https://forums.unrealengine.com/u/SupportiveEntity)\
**Post date:** [October 8, 2022, 11:02pm UTC](https://forums.unrealengine.com/t/inside-a-widget-instance-editable-reference-to-overlay-wont-stay-after-compile/665106/4 "2022-10-08T23:02:31Z")

</div>

Great info, can replicate it reliably now. Took a bit of doing but it’s kind of looking a little more intentional now. Didn’t have any of the oddities with the params until it went instance editable. Truthfully I’m not UI expert but I think in this case it might be worth the extra step of setting it in this case. I see what you mean on the clearing, since there’s no error it’s likely a normal cleanup.

Going to stick around in case someone knows better in this regard.

---

<div class="post-metadata">

**Author:** ![BIGTIMEMASTER](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/bigtimemaster/32/710746_2.png) [@BIGTIMEMASTER](https://forums.unrealengine.com/u/BIGTIMEMASTER)\
**Post date:** [October 8, 2022, 11:08pm UTC](https://forums.unrealengine.com/t/inside-a-widget-instance-editable-reference-to-overlay-wont-stay-after-compile/665106/5 "2022-10-08T23:08:42Z")

</div>

is that in 5 that you replicated or 4.27?

---

<div class="post-metadata">

**Author:** ![SupportiveEntity](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SupportiveEntity](https://forums.unrealengine.com/u/SupportiveEntity)\
**Post date:** [October 9, 2022, 1:31pm UTC](https://forums.unrealengine.com/t/inside-a-widget-instance-editable-reference-to-overlay-wont-stay-after-compile/665106/6 "2022-10-09T13:31:19Z")

</div>

I replicated it in 4.27, I didn’t finish trying it out in 5.0 before recognizing you were in 4.27 and swapping.
