Strip illegal character from filename
looks very nice, but will not work for me.
.......
Dim ar()
Dim i&
Dim ReplaceBy$
ReplaceBy = "_"
ar = Array(";", ":", ",", "\", "/", "*", "[", "]", "?",
"!", "'", "", "", "|", "$")
For i = 0 To UBound(ar)
Emne = Replace(1, Emne, ar(i), ReplaceBy, vbTextCompare)
Next
filnavn = Mdato & " " & Avsendernavn & " " & Emne & ".MSG"
txtPath = TextBox1.Value
myOlSel.Item(x).SaveAs txtPath & filnavn, olMSG 'export
message
|