Skip to content

Commit 42cbbde

Browse files
Fix JSON parsing of line feed characters
Added notes and submitted a PR on Tim Hall's official project, but I am correcting my version of the module to resolve an issue when saving multi-line values as JSON.
1 parent 36ef901 commit 42cbbde

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Version Control.accda.src/modules/modJsonConverter.bas

+3-1
Original file line numberDiff line numberDiff line change
@@ -590,7 +590,9 @@ Private Function json_ParseString(json_String As String, ByRef json_Index As Lon
590590
json_BufferAppend json_Buffer, vbFormFeed, json_BufferPosition, json_BufferLength
591591
json_Index = json_Index + 1
592592
Case "n"
593-
json_BufferAppend json_Buffer, vbCrLf, json_BufferPosition, json_BufferLength
593+
'json_BufferAppend json_Buffer, vbCrLf, json_BufferPosition, json_BufferLength
594+
' This should be treated as a line feed, not CrLf. - Adam 7/24/2023
595+
json_BufferAppend json_Buffer, vbLf, json_BufferPosition, json_BufferLength
594596
json_Index = json_Index + 1
595597
Case "r"
596598
json_BufferAppend json_Buffer, vbCr, json_BufferPosition, json_BufferLength

0 commit comments

Comments
 (0)