You are not logged in.
Hi,
AS suggested in forum I'm trying to make a new custom reader for my JSON like document https://synopse.info/files/html/Synopse … ml#TITL_52 and it goes well.
But I dont know who to handle array values and I cant find any sample.
One of the properties is array and trying many function including JSONArrayDecode cant decode the JSON array.
What function I should use for arrays?
Last edited by mohsenti (2017-03-24 23:07:55)
Offline
So I done something like this:
DA.Init(TypeInfo(TItem),V.FChilds);
DA.LoadFromJSON(Values[2]);
The only question is how can I set the value with the property "Childs" not the exact value like "FChilds"?
Offline
@mohsenti do you have some sample code using a custom reader for json serialization to share? I will be need that in a while and initial analysis of custom reader did not seem clear to me quickly so an exmple might pave way for me, many thanks:)
Offline
Hi,
I did that just like this part: https://synopse.info/files/html/Synopse … #TITLE_244
If you got problem, I will try to help you.
Offline
Thanks. I want to apply a custom reader to a json string returning an object list, any samples for this scenario?
Offline
There was sample in doc but I could not make it work and I used array for that and only for auto reader not custom readers.
Offline