Code: Select all
#File = 0
If CreateFile(#File, "_TOC.hhc", #PB_Ascii)
WriteStringN(#File, ~"\"><param name=\"Local\" value=\"html\\" + "name" +
~"\"></OBJECT>")
CloseFile(#File)
EndIfCode: Select all
#File = 0
If CreateFile(#File, "_TOC.hhc", #PB_Ascii)
WriteStringN(#File, ~"\"><param name=\"Local\" value=\"html\\" + "name" +
~"\"></OBJECT>")
CloseFile(#File)
EndIfCode: Select all
html\\"
Code: Select all
value=\"html\""Code: Select all
#File = 0
If CreateFile(#File, "_TOC.hhc", #PB_Ascii)
WriteStringN(#File, ~"\"><param name=\"Local\" value=\"html\"" + "name" +
~"\"></OBJECT>")
CloseFile(#File)
EndIfCode: Select all
Debug ~"\"><param name=\"Local\" value=\"html\"" + "name" +
~"\"></OBJECT>"Code: Select all
"><param name="Local" value="html"name"></OBJECT>Code: Select all
"><param name="Local" value="html\name"></OBJECT>Code: Select all
name.s = "Local"
value.s = "html\name"
a.s = Format("><param name=\'%s\' value=\'%s\'></OBJECT>", @name, @value)
debug a
Code: Select all
#File = 0
If CreateFile(#File, GetUserDirectory(#PB_Directory_Downloads) + "_TOC.hhc", #PB_Ascii)
WriteStringN(#File, ~"\"><param name=\"Local\" value=\"html\\" + "name" + ~"\"></OBJECT>")
CloseFile(#File)
EndIf

Code: Select all
Debug ~"\\" +
""Code: Select all
Debug ~"\\" + ""There should be no mistake here. A character that is special must also be escaped. That is, ~"\" is an error because there is no closing quote. In this line, ~"\\" the "\" character escapes the "\" character.NicTheQuick wrote: Thu Aug 15, 2024 3:59 pm Looks like a bug to me.
This is the shortest way to see the bug:Code: Select all
Debug ~"\\" + ""
There are two \s, the first one escapes the second one, then the quote closes the string.AZJIO wrote: Thu Aug 15, 2024 4:06 pmThere should be no mistake here. A character that is special must also be escaped. That is, ~"\" is an error because there is no closing quote. In this line, ~"\\" the "\" character escapes the "\" character.NicTheQuick wrote: Thu Aug 15, 2024 3:59 pm Looks like a bug to me.
This is the shortest way to see the bug:Code: Select all
Debug ~"\\" + ""