How To Use Parameter Or Variable In TEXT(), FName's Initialization?

Hi Community,

I know this is dumb question, but I really found nowhere for the answer. Please help me.

I know I can initialize a text like this way TEXT(“blablabla”), and a FNAME like this way FNAME(“blablabla”) or FNAME(TEXT(“blablabla”)).

But for example if I want to give a int32 varible or a FString varibale or combine multiple FString. How would I initialize them. I really appreciate it!

1 Like
FString MyString = TEXT("SomeTextHere");
FString::Printf(TEXT("Fancy string with another string: %s"), *MyString);

int32 MyInt = 5;
FString::Printf(TEXT("Fancy string with an int: %d"), 5);
2 Likes