How to control the visibility of special effects bound to Actor bones after hiding them?

I Want to control the visibility of special effects bound to my actor skeleton bons after SetActorHiddenInGame(true),please please please help!!
How to control the visibility of special effects bound to Actor bones after hiding them?

MyCode》》》》》》

this->SetActorHiddenInGame(true);

    USkeletalMeshComponent* CharacterMesh = this->GetMesh();
TArray<USceneComponent*> AttachChildren;
CharacterMesh->GetChildrenComponents(true, AttachChildren);

for (USceneComponent* Component : AttachChildren)
{
	if (Component->IsA<UNiagaraComponent>() || Component->IsA<UParticleSystemComponent>())
	{
		Component->SetHiddenInGame(false, true);
	}
}

PS:I’m sure this line of code“Component->SetHiddenInGame(false, true);” has been executed,but it doesn’t work.The Effect does’t shown in my game.How should I modify it to solve this problem?I sincerely hope that a great deity can help me solve this problem!

I solved this problem by myself.