# How to update a customized details panel?

**URL:** <https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028>\
**Category:** UI\
**Tags:** property, details-panel, customization, unreal-engine, editor, slate, question\
**Created:** [July 30, 2015, 5:26am UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028 "2015-07-30T05:26:25Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_7a9aff171](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_7a9aff171](https://forums.unrealengine.com/u/anonymous_user_7a9aff171)\
**Post date:** [July 30, 2015, 5:26am UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/1 "2015-07-30T05:26:25Z")

</div>

I have a custom property layout which should (in theory) display a variable number of children based on this property’s value. An adjustable length array, so to speak. So, my CustomizeChildren generates an appropriate number of elements, but I have to push Recompile to update the details panel after changing this value.  
I can call any function when it changes using IPropertyHandle::SetOnPropertyValueChanged. So, which function is used to refresh the details view?

I’ve tried NotifyPostChange and some other stuff but none of it works.  
I am sure this is possible - after all, TArray does work. But I can’t find its customization code, which would make my life easier. I haven’t tried to make full class details customizations yet, but I will if it’s necessary.

As a side question, where does the “reset to default” button come from? I want to either disable it, or make it reset to my values rather than being completely empty.

Some pictures:

Nicely generated at first

![]()

Changed ItemClass to new value

![52044-varnum2.png]()

After pressing Compile

![52045-varnum3.png]()

---

<div class="post-metadata">

**Author:** ![kamrann](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@kamrann](https://forums.unrealengine.com/u/kamrann)\
**Post date:** [July 30, 2015, 9:02am UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/2 "2015-07-30T09:02:04Z")

</div>

I don’t think you can do this with an `IPropertyTypeCustomization`. It looks like you want to customize one property based on the value of another? If so, you should do that through an `IDetailCustomization` for the containing class instead.

You’ll get a reference to an `IDetailLayoutBuilder`, which you can store and later call `ForceRefreshDetails` on to have the custom layout regenerated.

As for the reset to default, that has a very specific meaning which you shouldn’t try to change - it resets the property to the value specified in the class default object of the given instance’s class (or for a blueprint, to the value from the parent class). So if its behaviour isn’t what you expect, you should probably be putting the default values you want inside the C++ class constructor.

---

<div class="post-metadata">

**Author:** ![Randy\_Croucher1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Randy\_Croucher1](https://forums.unrealengine.com/u/Randy_Croucher1)\
**Post date:** [August 14, 2017, 5:55pm UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/3 "2017-08-14T17:55:12Z")

</div>

Old question, but I was needing the same thing and found this to work when needing a total refresh of the Details Panel…

```
FPropertyEditorModule& PropertyEditorModule = FModuleManager::GetModuleChecked<FPropertyEditorModule>("PropertyEditor");
PropertyEditorModule.NotifyCustomizationModuleChanged();
```

---

<div class="post-metadata">

**Author:** ![matan19](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@matan19](https://forums.unrealengine.com/u/matan19)\
**Post date:** [March 9, 2018, 8:58am UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/4 "2018-03-09T08:58:47Z")

</div>

after almost 3 years from the original question - but there is a solution.  
Get the parent category, and then the parent layout. Then just refresh.

```
IDetailCategoryBuilder &ParentCategory = StructBuilder.GetParentCategory();
    IDetailLayoutBuilder &LayoutBuilder = ParentCategory.GetParentLayout();
    LayoutBuilder.ForceRefreshDetails();
```

---

<div class="post-metadata">

**Author:** ![TigerFish89](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TigerFish89](https://forums.unrealengine.com/u/TigerFish89)\
**Post date:** [July 10, 2019, 1:39am UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/5 "2019-07-10T01:39:43Z")

</div>

Hi. I’m newbie in editor code. How can I get StructBuilder?

---

<div class="post-metadata">

**Author:** ![Randy\_Croucher1](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Randy\_Croucher1](https://forums.unrealengine.com/u/Randy_Croucher1)\
**Post date:** [July 10, 2019, 8:45pm UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/6 "2019-07-10T20:45:35Z")

</div>

I think in the source above, StructBuilder is probably the IDetailChildrenBuilder& passed in to CustomizeChildren in your derived IPropertyTypeCustomization class.

---

<div class="post-metadata">

**Author:** ![Shmoopy1701](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/shmoopy1701/32/1194536_2.png) [@Shmoopy1701](https://forums.unrealengine.com/u/Shmoopy1701)\
**Post date:** [February 5, 2021, 3:30pm UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/7 "2021-02-05T15:30:24Z")

</div>

^ this works perfectly. Put it in your Actor::PostEditChangeProperty() function. Don’t even have to #include anything.

---

<div class="post-metadata">

**Author:** ![turbanov](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/turbanov/32/710746_2.png) [@turbanov](https://forums.unrealengine.com/u/turbanov)\
**Post date:** [July 12, 2021, 3:00pm UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/8 "2021-07-12T15:00:27Z")

</div>

There is an another solution that I personally consider best and a good practice:

The `IPropertyTypeCustomizationUtils` type passed to the `CustomizeHeader` method contains a `IPropertyUtilities` facility via the `GetPropertyUtilities` method. This can be passed directly to your OnChange methods that should trigger the refresh as it in turn has the `ForceRefresh()` method.

This is how I do it:

```
void FTraitEntryCustomization::OnTypeChanged(TSharedPtr<IPropertyHandle> TypePropertyHandle,
									 TSharedPtr<IPropertyUtilities> Utils)
{
  if (Utils)
  {
	Utils->ForceRefresh();
  }

```

Later:

```
void FMyStructCustomization::CustomizeHeader(
TSharedRef<IPropertyHandle> StructPropertyHandle,
class FDetailWidgetRow& HeaderRow,
IPropertyTypeCustomizationUtils& StructCustomizationUtils)
{
  TSharedPtr<IPropertyHandle> TypePropertyHandle =
	  StructPropertyHandle->GetChildHandle(GET_MEMBER_NAME_CHECKED(FMyStruct, Type));
  OnTypeChanged(TypePropertyHandle, nullptr);

  TypePropertyHandle->SetOnPropertyValueChanged(
  	FSimpleDelegate::CreateSP(this, &FMyStructCustomization::OnTypeChanged,
							  TypePropertyHandle,
							  StructCustomizationUtils.GetPropertyUtilities()));

```

Note the first in-header call is passing nullptr to skip the first call to refresh on Widget creation. An assertion is raised otherwise.

---

<div class="post-metadata">

**Author:** ![Jambax](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/jambax/32/904177_2.png) [@Jambax](https://forums.unrealengine.com/u/Jambax)\
**Post date:** [November 17, 2021, 8:56pm UTC](https://forums.unrealengine.com/t/how-to-update-a-customized-details-panel/327028/9 "2021-11-17T20:56:29Z")

</div>

Thanks for this, holding onto the IPropertyUItilities was hitting a check(). Somehow passing it as a delegate param works fine.
