item := TreeView1.Items.AddChild(item, '_array');
for i := 0 to arr.count - 1 do
begin
- s := arr.Items[i].ToString;
val := arr.Items[i];
if val is TJSONObject then
loop(item, val as TJSONObject)
else if val is TJSONArray then
arrloop(item, val as TJSONArray)
else
+ begin
+ s := arr.Items[i].ToString;
TreeView1.Items.AddChild(item, s);
+ end;
end;
end;
for i := 0 to JSON.count - 1 do
begin
pair := JSON.Pairs[i];
- val := pair.JsonValue;
+ if pair = nil then
+ begin
+ TreeView1.Items.AddChild(item, 'error');
+ Showmessage('\93à\95\94\83G\83\89\81[\82É\82æ\82è\92\86\92f\82µ\82Ü\82µ\82½');
+ Exit;
+ end
+ else
+ val := pair.JsonValue;
if val is TJSONObject then
begin
s := pair.JsonString.ToString + ':';
end
else if val is TJSONArray then
begin
- s := pair.JsonString.ToString;
+ s := pair.JsonString.ToString + ':';
arrloop(TreeView1.Items.AddChild(item, s), pair.JsonValue as TJSONArray);
end
else
<FrameworkType>VCL</FrameworkType>
<MainSource>json_checker.dpr</MainSource>
<Base>True</Base>
- <Config Condition="'$(Config)'==''">Release</Config>
+ <Config Condition="'$(Config)'==''">Debug</Config>
<Platform Condition="'$(Platform)'==''">Win64</Platform>
<TargetedPlatforms>3</TargetedPlatforms>
<AppType>Application</AppType>