From c2cc949368ab66426a42594252957e68f1f19b70 Mon Sep 17 00:00:00 2001 From: stenci Date: Wed, 2 Jan 2019 11:21:06 -0600 Subject: [PATCH] Allow use of double quotes on keys This change allows to manage this type of keys: {"1/4\"": "One quarter inch"} --- JsonConverter.bas | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/JsonConverter.bas b/JsonConverter.bas index 3810579..1bdca12 100644 --- a/JsonConverter.bas +++ b/JsonConverter.bas @@ -380,9 +380,9 @@ Public Function ConvertToJson(ByVal JsonValue As Variant, Optional ByVal Whitesp End If If json_PrettyPrint Then - json_Converted = vbNewLine & json_Indentation & """" & json_Key & """: " & json_Converted + json_Converted = vbNewLine & json_Indentation & """" & json_Encode(json_Key) & """: " & json_Converted Else - json_Converted = """" & json_Key & """:" & json_Converted + json_Converted = """" & json_Encode(json_Key) & """:" & json_Converted End If json_BufferAppend json_Buffer, json_Converted, json_BufferPosition, json_BufferLength