Hello Luciano,
I tried your example with a 500 KB document in the 'base64' field. It worked nicely, and all 500 KB of the document loaded into my program.
Can you tell me more about the problem you're experiencing? What do you mean when you say 'reading the node does not bring me anything'? do you mean that the variable named 'node' is *NULL after calling yajl_object_find? Or do you mean that yajl_get_string_buf() is returning an error?
It is not clear what problem you're having.
-SK
I am trying to extract the PDF file inside the Json but reading the node does not bring me anything. Could it be because of the file size?
Source copy
docNode=yajl_stmf_load_tree('/archivos/tmp/Maderdescarga.Json':val = yajl_object_find(node:'filename'); Does not bring data. and it's the same with 'base64'
errMsg );
if errMsg <> '';
PError = '1';
endif;
PError = 'S';
Node = YAJL_object_find(docNode: 'data');
val = yajl_object_find(node:'filename');
auxiliar = yajl_get_String(val);
RC = yajl_get_String_buf(val: %addr(VALue): %size(Value));
val = yajl_object_find(node:'base64');
RC = yajl_get_String_buf(val: %addr(VALue): %size(Value));
I copy some lines from the json that the program reads:{"status":{"code":200,"mensaje":"OK","detalle":"OK"},"data":{"filename":"587616678.tif","base64":"data:tif;base64,SUkqAMxfAQCAP+BP9\/ACDQeDAGBwuGQ2HQ+IRGJROKRWLReMRmNQx+QuCwiDwqNyOSSWTSeUSmBx2Bx+QACRSqZTOaTWbQ6WQKXSCYzefT+gUGITmCS+E0KkUmlTOiTuET2l1GpVOI02jTCqVmtVmrUaoVuwWGb12X1+xWe0SayTy0223SO10+33O6RO4wi63m9SuGVcAH+94G50R\/37AYLEWjCICr4fE4+t4vG5DKVyGYyjY7K5uk5LM5zQUjPS\/NaHTTXRyDS6fWSnCMCrj\/W7OVa\/Y7TcWqGbCjbLc7+NbajB\/gcWL8KXgfjcu7burgPmdGH6mEdDpde+QvMS\/rdjr4S\/d3vdG7wflePpeWDav0cDwS8Tef28zCCCD\/azfP3Qx4GAAA+eDfP08iGHwfwLwGxQHqEwkEraeD5J\/BsHLQc54wZCi5m+fsMQyrZ9ocT5\/D+fziJ9CcPKWeUBIGT5\/h+fDxNRFKtQChpfn\/ET8trGisxshjZE+ZgcQlHqqHg1bAGeaB+PZHkjKlC6GyUYMRxPKEoocMAHneYZ\/RYmkUSwn58ocMJ\/y7L8rzGpUyoaM80GOf5vzXNikTchk4HOR5\/mfO..................................................... and continue. Total size : 149KB
Can you help me with this?
-- _______________________________________________ Ftpapi mailing list Ftpapi@xxxxxxxxxxxxxxxxxxxxxx http://scottklement.com/mailman/listinfo/ftpapi