请教VB内码转换语言怎么使用
Dim iReadNumber As Integer '读文件号Dim iWriteNumber As Integer '写文件号
Dim mem() As Byte 'byte数组
Dim strFileName As String '文件名
Dim lLength As Long '文件长度
'`将文件内容读入mem byte数组
iReadNumber = FreeFile
strFileName = TextFileName.Text
lLength = FileLen(strFileName)
ReDim mem(lLength) As Byte
Open strFileName For Binary As #iReadNumber
Get #iReadNumber, , mem
Close #iReadNumber
'`将mem数组转换为Big5码所对应的Unicode码
mem = StrConv(mem, vbUnicode, &H404)
'`再将Unicode码转换为GBK编码
mem = StrConv(mem, vbFromUnicode, &H804)
'`写到源文件里去
iWriteNumber = FreeFile
Kill strFileName
Open strFileName For Binary As #iWriteNumber
Put #iWriteNumber, , mem
Close #iWriteNumber
'`结束