Jeden odebere diakritiku a druhý vynechá mezery.
Function StripAccent(thestring As String)
Dim A As String * 1
Dim B As String * 1
Dim i As Integer
Const AccChars = "áäčďéěíĺľňóôőöŕšťúůűüýřžÁÄČĎÉĚÍĹĽŇÓÔŐÖŔŠŤÚŮŰÜÝŘŽ,./-"
Const RegChars = "aacdeeillnoooorstuuuuyrzAACDEEILLNOOOORSTUUUUYRZ"
For i = 1 To Len(AccChars)
A = Mid(AccChars, i, 1)
B = Mid(RegChars, i, 1)
thestring = Replace(thestring, A, B)
Next
StripAccent = thestring
End Function
Když např.: 2020/Jan Zobrazí to 2020 Jan.
K čemu chci docílit:
2020Jan
Děkuji