question

Riccardo Iengo avatar image
Riccardo Iengo asked

FUpdateUserDataRequest how to set 'Data'?

I need to call UpdateUserReadOnlyData but in the Request I can't set the Request.Data

Can someone help me with this? Here's my code, thanks!

	CustomData->SetStringField("Test", JsonOut);
	
	auto UploadData = PlayFab::FJsonKeeper();
	UploadData.readFromValue(MakeShareable(new FJsonValueObject(CustomData)));


	PlayFab::ServerModels::FUpdateUserDataRequest Request;
	Request.Data = UploadData; <---NOT WORKING!
	Request.PlayFabId = GameInstance->PlayFabID;
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Gosen Gao avatar image
Gosen Gao answered

It seems that the data types do not match, you can replace it with Request.Data.Add("test", JsonOut);

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.