Construction script: Static mesh parameter greyed out, and then the static mesh disappears .... why?

HI ,
I’m struggling with a blueprint , it’s an actor that has a static mesh. In my app, i want ( in editor, not in runtime) right click on a mesh, and replace it with that actor. Instead adding the mesh to the actor manually , i made something in the CONSTRUCTION SCRIPT of the actor, to assign the mesh and even apply a material, and it works :slight_smile:

[ATTACH=JSON]{“data-align”:“none”,“data-size”:“full”,“data-tempid”:“temp_134796_1523523051544_713”}[/ATTACH]

The problem is, whenever i make any change to that actor (if i move it, or change material …) the mesh disappears instantly !! I know that in Construction Script it’s special … whenever you make a change, the whole script is executed again, but i can’t figure out how to solve that, i tried with some variables , but it’s still the same problem.
And before the mesh disappears, there is also something i don’t understand ! If i add an empty actor to the level, and then add manually a mesh to the actor, well … there is absolutely no problem ! It doesn’t disappears if i make a change, and it looks like this :

But, if i replace a mesh with an actor and assign automatically the mesh to it (and it works), the parameter will looks like this in the editor:

IT’S GREYED !!! i really don’t get it !
any help please? :slight_smile:

I’ve just run into the exact same issue. Happens in UE5 as well.

I have no idea why the static mesh property of the static mesh component is greyed out the first time it is assigned a mesh in the construction script. I’ve never seen this happen before until now.

Then when I move the actor, the static mesh property on the static mesh component is cleared so the actor loses its mesh. All the other properties of the actor remain intact.

What I’ve found though, is that if I forcibly reassign the mesh to the static mesh component again (by using a run in editor event), then it all works fine. I can move the actor around without it losing its mesh. I also note then that the static mesh property is not greyed out like before, so I can change it manually if desired.

Something strange is happening and I can’t figure it out.