PDA

View Full Version : Test excelfox Corruptions January 2021 *



DocAElstein
01-20-2021, 10:34 PM
Some time around Middle January 2021 some strange corruptions occurred.
I think they all appeared at the same time, and it could have been on 14th January, 2021. But I am not 100% sure.

This thread caught my attention first,
https://excelfox.com/forum/showthread.php/2302-quot-What%c3%a2%e2%82%ac%e2%84%a2s-in-a-String-quot-VBA-break-down-Loop-through-character-contents-of-a-string
but I have seen the problem elsewhere also
here is a screen shot from now
As seen in January 2021
https://i.imgur.com/x3EmtPi.jpg


For comparison with what it was like previously, we can find many archived versions, for example http://web.archive.org/web/20200321110623/https://excelfox.com/forum/showthread.php/2302-quot-What%E2%80%99s-in-a-String-quot-VBA-break-down-Loop-through-character-contents-of-a-string
_ Archived version from March 2020
https://i.imgur.com/tY5A9qG.jpg


It looks like we have a problem with the non straight quote things



Its very difficult to analyse these characters because they have habit of changing depending on where you copy and paste them from or to For example, Some of us may have had the experience that when copying a code from somewhere into a code module, quotes get changed to the non straight ones resulting in syntax errors in a macro


Sub HelloGoodQuotes()
MsgBox Prompt:="Hello Good straight Quotes"
End Sub
Sub HellobadQuotes()
MsgBox Prompt:=“Hello Bad non straight Quotes”
End Sub

If I do my WotchaGotMacro, ( coincidentally shared at the example corrupt Thread) , .._

Sub excelfoxCoruptions() ' https://excelfox.com/forum/showthread.php/2704-Test-excelfox-Corruptions-January-2021
' “He” & “l” & “l” & “o” & vbCr & vbLf t’s
Call WtchaGot_Unic_NotMuchIfYaChoppedItOff("“’”“”") ' https://excelfox.com/forum/showthread.php/2302-quot-What%E2%80%99s-in-a-String-quot-VBA-break-down-Loop-through-character-contents-of-a-string
End Sub
_.. then I get these results:

ChrW(8220) & ChrW(8217) & ChrW(8221) & ChrW(8220) & ChrW(8221)

Row\Col
E
F

1
20 Jan 2021
Lenf is 5“’”“”


21 “8220


32 ’8217


43 ”8221


54 “8220


65 ”8221
Worksheet: WotchaGotInString

They seem to be tying up with published info, such as here : https://www.vertex42.com/ExcelTips/unicode-symbols.html

_.___________________

I can repair , or rather replace, my corrupt posts from the copy of the posts that I have in Microsoft Word.
To be on the safe side, to help avoid such corruptions in the future, I should probably best change all my quotes in text to straight ones. One small snag in this is that trying to do it manually returns some peculiar results. It seems that Microsoft Word has some rules / processes which convert quotes. I don't understand them yet.
Luckily a macro does not seem to suffer from these problems: If I select the text in which I want to "sanitise" the quotes, the run this macro, then all my quotes get changed to straight ones


Sub QuoteChange() ' Ctrl+Shift+q
With Selection
' .Text = Replace(.Text, ChrW(8220), Chr(34), 1, -1, vbBinaryCompare) ' Chr(34) is "
' .Text = Replace(.Text, ChrW(8221), Chr(34), 1, -1, vbBinaryCompare)
' .Text = Replace(.Text, ChrW(8217), Chr(39), 1, -1, vbBinaryCompare) ' Chr(39) is '
' or
.Text = Replace(Replace(Replace(.Text, ChrW(8217), Chr(39), 1, -1, vbBinaryCompare), ChrW(8221), Chr(34), 1, -1, vbBinaryCompare), ChrW(8220), Chr(34), 1, -1, vbBinaryCompare)
End With
End Sub

Excel Fox
01-25-2021, 02:26 PM
Looks like it's a Windows-1252 vs UTF-8 issue. I am sure I'll fix it - just need some time - hopefully won't break anything if I show some patience.

DocAElstein
01-25-2021, 04:05 PM
A secondary strange effect occurs also sometimes as a result of this issue

Let me try to explain this secondary effect
If I try to post some things which include non straight quotes, then sometimes things after the non straight quote will vanish.
( It is very inconsistent. It will depend on what is after the non straight quote ).

Example:
If I try to post this text :
OnlySomeOfThisWillPost.txt : https://app.box.com/s/vdexh4z03f4buygtr2fzdc29jbyz1ir3
http://i.imgur.com/9G0Qs3x.jpg
https://i.imgur.com/9G0Qs3x.jpg

then only this much of it will get posted
DhADHHDKJHDAHDAKJDHKAJDHKJ
Everything after the non straight quote will not post. It will not appear in the final post



There are no strange effects from posting this
AllOfThisWillPost.txt https://app.box.com/s/l1vujsrdiu7l00q8jgehgi8qg1li6j15

DhADHHDKJHDAHDAKJDHKAJDHKJ's

AlkhdlkDLKHDLKHDLKHD
ahdlAKDHDDHAH
because in that last text I have a straight quote, ' , there are no strange effects


I think this secondary effect also appeared at the same time as the other issues. I think something happened around middle January 2021 to cause all this, but I am not 100% sure about that






Just to clarify what I am saying in this post..
In the two text files is identical text. The only difference is that OnlySomeOfThisWillPost.txt has a non straight quote, whereas AllOfThisWillPost.txt uses a straight quote.
If I copy the text from AllOfThisWillPost.txt into the forum editor and post, then all the text will appear in the final post.
But if I copy the text from OnlySomeOfThisWillPost.txt into the forum editor and post, then only the text before the quote will appear in the final post

DocAElstein
01-25-2021, 04:17 PM
DhADHHDKJHDAHDAKJDHKAJDHKJ

DocAElstein
01-25-2021, 04:19 PM
DhADHHDKJHDAHDAKJDHKAJDHKJ's

AlkhdlkDLKHDLKHDLKHD
ahdlAKDHDDHAH

DocAElstein
01-25-2021, 06:37 PM
Note: posts 3 - 5 are a secodary problem.
I don’t know how to create the corruptions mentioned in post #1. They all appeared , I think at once , in middle January 2021.
What happened is that Posts including non straight quote became corrupted at the places where those non straight quotes had been.

DocAElstein
01-25-2021, 07:01 PM
Here more examples like in Post #1

Look at the titles now here:
https://excelfox.com/forum/forumdisplay.php/11-Tips-Tricks-amp-Downloads-(No-Questions)
https://i.imgur.com/6SQAVmk.jpg


Now compare with a web archive from last April
http://web.archive.org/web/20200429155133/https://excelfox.com/forum/forumdisplay.php/11-Tips-Tricks-amp-Downloads-(No-Questions)
https://i.imgur.com/PXLA7JR.jpg

In fact , this problem is caused apparently by the 3 dots character

( Let me go see if I can figure that what those 3 characters are being seen as - , I think I have seen that problem somewhere else )

Excel Fox
01-25-2021, 07:17 PM
Testing the sentence whether it's coming after this ‘ OK it is displaying

DocAElstein
01-25-2021, 07:30 PM
Check this out –

If I fiddle around in Microsoft Word and/ or in text files and various editor windows, I can find a way to see 3 dots slightly differently…
https://i.imgur.com/I9VDn7D.jpg

Now I run my macro on it like this
https://i.imgur.com/9QDTmMT.jpg

This is what it tells me: So its telling me that 3 dots can be interpreted as Character(8230)
https://i.imgur.com/lWwZ79S.jpg

That ties up with here https://www.vertex42.com/ExcelTips/unicode-symbols.html
https://i.imgur.com/0ysJIWx.jpg

Note: In posting all this I need to be careful if I post 3 dots, because I sometimes get the secondary effect which I talked about in posts #3 - #5.
That is why I am using images instead of posting any text with 3 dots in it

Excel Fox
01-25-2021, 07:41 PM
Can you test it now

DocAElstein
01-25-2021, 07:51 PM
Test posting the text from the text file with a non straight quote in it, OnlySomeOfThisWillPost.txt


DhADHHDKJHDAHDAKJDHKAJDHKJ’s

AlkhdlkDLKHDLKHDLKHD
ahdlAKDHDDHAH




At a first glance, it seems that you have fixed everything somehow!!!!
So far I see these two things

_ It seems that any old postings with non straight quotes which got corrupted have changed now to all show straight quotes and they are no longer corrupted.
_ if I try to post something with a non straight quote it gets all posted

Excel Fox
01-25-2021, 07:58 PM
_ It seems that any old postings with non straight quotes which got corrupted have changed now to all show straight quotes and they are no longer corrupted.


Collateral damage I guess - but with success!

DocAElstein
01-25-2021, 08:05 PM
_ and I also see that you have taken out the corruptions from 3 dots by removing the 3 dots...

all looks good!

My ( very uneducated ) guess had been that something had caused some permanent damage that probably could only be fixed by restarting the forum to some earlier time - ( just goes to show how little idea I have currently of how to run and/ or fix a problem in forum software ;) )

( but I did just fix the bug that stoped being able to access page 2 of this Thread
I just changed the title to
Test excelfox Corruptions January 2021 *
it had previously been
Test excelfox Corruptions January 2021

If you have a number in the end of a title then the page 2 button (http://i.imgur.com/dNyzEwy.jpg)does not work properly - you end up going to some other Thread
- Kris showed me how to fix that a few years ago )

Excel Fox
01-25-2021, 08:07 PM
A few things that helped (Character Encoding ISO-8859-1 to UTF-8)

https://digwp.com/2011/07/clean-up-weird-characters-in-database/
https://www.i18nqa.com/debug/utf8-debug.html
https://forum.vbulletin.com/forum/vbulletin-4/vbulletin-4-questions-problems-and-troubleshooting/4385463