解决access数据库记录中含有日文时内存溢出的函数
作者:admin 日期:2007-11-07
Function EncodeJP(byval strContent)
If strContent="" Then Exit Function
'SQL版本不进行编码
If IS_SQLDATA=1 Then
EncodeJP=strContent
Exit Function
End If
strContent=Replace(strContent,"ガ","ガ")
strContent=Replace(strContent,"ギ","ギ")
strContent=Replace(strContent,"グ","グ")
strContent=Replace(strContent,"ア","ア")
strContent=Replace(strContent,"ゲ","ゲ")
strContent=Replace(strContent,"ゴ","ゴ")
strContent=Replace(strContent,"ザ","ザ")
strContent=Replace(strContent,"ジ","ジ")
strContent=Replace(strContent,"ズ","ズ")
strContent=Replace(strContent,"ゼ","ゼ")
strContent=Replace(strContent,"ゾ","ゾ")
strContent=Replace(strContent,"ダ","ダ")
strContent=Replace(strContent,"ヂ","ヂ")
strContent=Replace(strContent,"ヅ","ヅ")
strContent=Replace(strContent,"デ","デ")
strContent=Replace(strContent,"ド","ド")
strContent=Replace(strContent,"バ","バ")
strContent=Replace(strContent,"パ","パ")
strContent=Replace(strContent,"ビ","ビ")
strContent=Replace(strContent,"ピ","ピ")
strContent=Replace(strContent,"ブ","ブ")
strContent=Replace(strContent,"ブ","ブ")
strContent=Replace(strContent,"プ","プ")
strContent=Replace(strContent,"ベ","ベ")
strContent=Replace(strContent,"ペ","ペ")
strContent=Replace(strContent,"ボ","ボ")
strContent=Replace(strContent,"ポ","ポ")
strContent=Replace(strContent,"ヴ","ヴ")
EncodeJP=strContent
End Function
广告位