개발자의 사투

Delphi JSONObject 값 가져오기 본문

컴방/델파이

Delphi JSONObject 값 가져오기

개발자룽 2020. 2. 18. 16:07

var
  tempObj : TJSONObject;
begin
  tempObj := TJSONObject.Create;

  tempObj.AddPair('A', '1')
  tempObj.AddPair('B', '2')
  tempObj.AddPair('C', '3')

  showmessage(tempObj.Get('A').JsonValue.Value);
  // '1'

end;

 

array 찾아올때

///(TJSONArray.Items[i] as TJSONObject).Get('A').JsonValue.Value;

Comments