Skip to content


Remove MS Word Smart Quotes in Vbscript

just a little tidbit that was driving me crazy.

Haven’t used ASCW and CHRW much, but here it goes:

strtitle = Replace(strTitle,ChrW(8211),”–“)
strtitle = Replace(strTitle,ChrW(8212),”–“)
strtitle = Replace(strTitle,ChrW(8216),”‘”)
strtitle = Replace(strTitle,ChrW(8217),”‘”)
strtitle = Replace(strTitle,ChrW(8220),””””)
strtitle = Replace(strTitle,ChrW(8221),””””)
strtitle = Replace(strTitle,ChrW(8226),”*”)
strtitle = Replace(strTitle,ChrW(8482),””)
strtitle = Replace(strTitle,ChrW(8230),”.”)

Be Sociable, Share!

Posted in code.

0 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.

Some HTML is OK

or, reply to this post via trackback.